dda-backup/infrastructure/docker/image/resources/install.sh

25 lines
748 B
Bash
Executable file

#!/bin/bash
set -exo pipefail
function main() {
{
apt-get update
apt-get upgrade -y
apt-get install -qqy ca-certificates curl gnupg postgresql-client-14
} > /dev/null
mkdir /usr/share/postgresql-common/pgdg
curl -Sso /usr/share/postgresql-common/pgdg/apt.postgresql.org.asc --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc
sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt jammy-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
update-ca-certificates
install -m 0400 /tmp/functions.sh /usr/local/lib/
install -m 0400 /tmp/pg-functions.sh /usr/local/lib/
install -m 0400 /tmp/file-functions.sh /usr/local/lib/
cleanupDocker
}
source /tmp/install_functions.sh
main