|
@@ -61,8 +61,8 @@ sed -i "s/zzz/$password/g" /etc/cron.daily/fusionpbx-backup.sh
|
|
cwd=$(pwd)
|
|
cwd=$(pwd)
|
|
cd /tmp
|
|
cd /tmp
|
|
#add the databases, users and grant permissions to them
|
|
#add the databases, users and grant permissions to them
|
|
-sudo -u postgres psql -c "DROP SCHEMA public cascade;";
|
|
|
|
-sudo -u postgres psql -c "CREATE SCHEMA public;";
|
|
|
|
|
|
+sudo -u postgres psql -d fusionpbx -c "DROP SCHEMA public cascade;";
|
|
|
|
+sudo -u postgres psql -d fusionpbx -c "CREATE SCHEMA public;";
|
|
sudo -u postgres psql -c "CREATE DATABASE fusionpbx;";
|
|
sudo -u postgres psql -c "CREATE DATABASE fusionpbx;";
|
|
sudo -u postgres psql -c "CREATE DATABASE freeswitch;";
|
|
sudo -u postgres psql -c "CREATE DATABASE freeswitch;";
|
|
sudo -u postgres psql -c "CREATE ROLE fusionpbx WITH SUPERUSER LOGIN PASSWORD '$password';"
|
|
sudo -u postgres psql -c "CREATE ROLE fusionpbx WITH SUPERUSER LOGIN PASSWORD '$password';"
|