make database host dynamic. (#334)

Co-authored-by: Gill Abada <gill@callifi.com>
This commit is contained in:
Gill Abada 2020-07-31 11:17:08 -04:00 committed by GitHub
parent 5d3a0d2624
commit 278e65c2e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 10 additions and 5 deletions

View File

@ -26,6 +26,7 @@ sudo -u postgres /usr/pgsql-9.4/bin/psql -c "ALTER USER freeswitch WITH PASSWORD
mkdir -p /etc/fusionpbx
chown -R freeswitch:daemon /etc/fusionpbx
cp fusionpbx/config.php /etc/fusionpbx
sed -i /etc/fusionpbx/config.php -e s:"{database_host}:$database_host:"
sed -i /etc/fusionpbx/config.php -e s:'{database_username}:fusionpbx:'
sed -i /etc/fusionpbx/config.php -e s:"{database_password}:$database_password:"

View File

@ -32,7 +32,7 @@
//$db_path = '/var/www/fusionpbx/secure'; //the path is determined by a php variable
//pgsql: database connection information
$db_host = 'localhost'; //set the host only if the database is not local
$db_host = '{database_host}';
$db_port = '5432';
$db_name = 'fusionpbx';
$db_username = '{database_username}';

View File

@ -34,6 +34,7 @@ sed -i "s/zzz/$database_password/g" /etc/cron.daily/fusionpbx-maintenance
mkdir -p /etc/fusionpbx
chown -R www-data:www-data /etc/fusionpbx
cp fusionpbx/config.php /etc/fusionpbx
sed -i /etc/fusionpbx/config.php -e s:"{database_host}:$database_host:"
sed -i /etc/fusionpbx/config.php -e s:'{database_username}:fusionpbx:'
sed -i /etc/fusionpbx/config.php -e s:"{database_password}:$database_password:"

View File

@ -32,7 +32,7 @@
//$db_path = '/var/www/fusionpbx/secure'; //the path is determined by a php variable
//pgsql: database connection information
$db_host = 'localhost'; //set the host only if the database is not local
$db_host = '{database_host}';
$db_port = '5432';
$db_name = 'fusionpbx';
$db_username = '{database_username}';

View File

@ -69,6 +69,7 @@ cd $cwd
mkdir -p /etc/fusionpbx
chown -R www-data:www-data /etc/fusionpbx
cp fusionpbx/config.php /etc/fusionpbx
sed -i /etc/fusionpbx/config.php -e s:"{database_host}:$database_host:"
sed -i /etc/fusionpbx/config.php -e s:'{database_username}:fusionpbx:'
sed -i /etc/fusionpbx/config.php -e s:"{database_password}:$database_password:"

View File

@ -32,7 +32,7 @@
//$db_path = '/var/www/fusionpbx/secure'; //the path is determined by a php variable
//pgsql: database connection information
$db_host = 'localhost'; //set the host only if the database is not local
$db_host = '{database_host}';
$db_port = '5432';
$db_name = 'fusionpbx';
$db_username = '{database_username}';

View File

@ -32,6 +32,7 @@ if [ .$nginx_enabled = .'true' ]; then
mkdir -p /etc/fusionpbx
chown -R www:www /etc/fusionpbx
cp fusionpbx/config.php /etc/fusionpbx
sed -i' ' -e s:"{database_host}:$database_host:" /etc/fusionpbx/config.php
sed -i' ' -e s:'{database_username}:fusionpbx:' /etc/fusionpbx/config.php
sed -i' ' -e s:"{database_password}:$database_password:" /etc/fusionpbx/config.php

View File

@ -32,7 +32,7 @@
//$db_path = '/var/www/fusionpbx/secure'; //the path is determined by a php variable
//pgsql: database connection information
$db_host = 'localhost'; //set the host only if the database is not local
$db_host = '{database_host}';
$db_port = '5432';
$db_name = 'fusionpbx';
$db_username = '{database_username}';

View File

@ -34,6 +34,7 @@ sed -i "s/zzz/$database_password/g" /etc/cron.daily/fusionpbx-maintenance
mkdir -p /etc/fusionpbx
chown -R www-data:www-data /etc/fusionpbx
cp fusionpbx/config.php /etc/fusionpbx
sed -i /etc/fusionpbx/config.php -e s:"{database_host}:$database_host:"
sed -i /etc/fusionpbx/config.php -e s:'{database_username}:fusionpbx:'
sed -i /etc/fusionpbx/config.php -e s:"{database_password}:$database_password:"

View File

@ -32,7 +32,7 @@
//$db_path = '/var/www/fusionpbx/secure'; //the path is determined by a php variable
//pgsql: database connection information
$db_host = 'localhost'; //set the host only if the database is not local
$db_host = '{database_host}';
$db_port = '5432';
$db_name = 'fusionpbx';
$db_username = '{database_username}';