Update postgres.sh

This commit is contained in:
FusionPBX 2017-11-06 17:55:38 -07:00 committed by GitHub
parent 2fe881b6af
commit 04f78936e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 1 deletions

View File

@ -33,9 +33,15 @@ if [ ."$database_repo" = ."official" ]; then
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add -
apt-get update && apt-get upgrade -y
apt-get install -y --force-yes sudo postgresql
if [ ."$database_version" = ."latest" ]; then
apt-get install -y --force-yes sudo postgresql
fi
if [ ."$database_version" = ."9.6" ]; then
apt-get install -y --force-yes sudo postgresql-9.6
fi
fi
#Add PostgreSQL and BDR REPO
#add PostgreSQL and 2ndquadrant repos
if [ ."$database_repo" = ."2ndquadrant" ]; then
echo 'deb http://apt.postgresql.org/pub/repos/apt/ jessie-pgdg main' >> /etc/apt/sources.list.d/postgresql.list
echo 'deb http://packages.2ndquadrant.com/bdr/apt/ jessie-2ndquadrant main' >> /etc/apt/sources.list.d/2ndquadrant.list