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

25 lines
815 B
Bash
Raw Normal View History

2020-12-04 17:10:24 +00:00
#!/bin/bash
set -exo pipefail
2023-11-03 09:48:24 +00:00
2021-03-12 14:40:26 +00:00
function main() {
{
2023-12-07 19:52:34 +00:00
upgradeSystem
apt-get install -qqy ca-certificates curl gnupg postgresql-client-14
curl -Ss --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc | gpg --dearmor | tee /etc/apt/trusted.gpg.d/postgresql-common_pgdg_archive_keyring.gpg
sh -c 'echo "deb [signed-by=/etc/apt/trusted.gpg.d/postgresql-common_pgdg_archive_keyring.gpg] https://apt.postgresql.org/pub/repos/apt jammy-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
upgradeSystem
} > /dev/null
2021-03-12 14:40:26 +00:00
update-ca-certificates
2020-12-04 17:10:24 +00:00
2021-03-12 14:40:26 +00:00
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