Update postgres.sh

This commit is contained in:
FusionPBX 2017-03-05 10:45:03 -07:00 committed by GitHub
parent 868b1a5d12
commit b400af5bff
1 changed files with 7 additions and 0 deletions

View File

@ -5,6 +5,8 @@ cd "$(dirname "$0")"
#includes
. ./config.sh
. ./colors.sh
. ./environment.sh
#send a message
echo "Install PostgreSQL"
@ -15,6 +17,11 @@ password=$(dd if=/dev/urandom bs=1 count=20 2>/dev/null | base64)
#install message
echo "Install PostgreSQL and create the database and users\n"
#use the system database repo for arm
if [ .$cpu_architecture = .'arm' ]; then
database_repo="system"
fi
#included in the distribution
if [ ."$database_repo" = ."system" ]; then
apt-get install -y --force-yes sudo postgresql