From 9101ad6efc1a9277fd71f97a665250ec169f5fe0 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Thu, 23 Apr 2020 16:12:09 +0300 Subject: [PATCH] don't rely on DB_HOST, DB_TYPE, and DB_PORT set in config.php-dist; set proper values on startup --- app/startup.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/startup.sh b/app/startup.sh index b4c5572..3188fe6 100755 --- a/app/startup.sh +++ b/app/startup.sh @@ -73,6 +73,9 @@ if [ ! -s $DST_DIR/config.php ]; then -e "s/define('DB_USER'.*/define('DB_USER', '$DB_USER');/" \ -e "s/define('DB_NAME'.*/define('DB_NAME', '$DB_NAME');/" \ -e "s/define('DB_PASS'.*/define('DB_PASS', '$DB_PASS');/" \ + -e "s/define('DB_HOST'.*/define('DB_HOST', '$DB_HOST');/" \ + -e "s/define('DB_TYPE'.*/define('DB_TYPE', 'pgsql');/" \ + -e "s/define('DB_PORT'.*/define('DB_PORT', 5432);/" \ -e "s/define('PLUGINS'.*/define('PLUGINS', 'auth_internal, note, nginx_xaccel');/" \ -e "s/define('SELF_URL_PATH'.*/define('SELF_URL_PATH','$SELF_URL_PATH');/" \ < $DST_DIR/config.php-dist > $DST_DIR/config.php