Use env vars for PHP app

master
andryyy 2016-12-14 21:10:11 +01:00
parent 87661da5a8
commit 774320d5e8
3 changed files with 8 additions and 6 deletions

View File

@ -34,7 +34,6 @@ server {
deny all; deny all;
} }
location ^~ /Microsoft-Server-ActiveSync { location ^~ /Microsoft-Server-ActiveSync {
proxy_pass http://sogo/SOGo/Microsoft-Server-ActiveSync; proxy_pass http://sogo/SOGo/Microsoft-Server-ActiveSync;
proxy_connect_timeout 1000; proxy_connect_timeout 1000;
@ -85,7 +84,7 @@ server {
} }
location /SOGo/WebServerResources/ { location /SOGo/WebServerResources/ {
alias /usr/lib/GNUstep/SOGo/WebServerResources/; alias /usr/lib/GNUstep/SOGo/WebServerResources/;
allow all; allow all;
} }

View File

@ -9,9 +9,9 @@ This file will be reset on upgrades.
// SQL database connection variables // SQL database connection variables
$database_type = "mysql"; $database_type = "mysql";
$database_host = "mysql"; $database_host = "mysql";
$database_user = "mailcow"; $database_user = getenv('DBUSER');
$database_pass = "mysafepasswd"; $database_pass = getenv('DBPASS');
$database_name = "mailcow"; $database_name = getenv('DBNAME');
// Where to go after adding and editing objects // Where to go after adding and editing objects
// Can be "form" or "previous" // Can be "form" or "previous"
@ -30,5 +30,4 @@ $DEFAULT_LANG = "en";
// simplex, slate, spacelab, superhero, united, yeti // simplex, slate, spacelab, superhero, united, yeti
// See https://bootswatch.com/ // See https://bootswatch.com/
$DEFAULT_THEME = "lumen"; $DEFAULT_THEME = "lumen";
?> ?>

View File

@ -70,6 +70,10 @@ services:
- ./data/web:/web:ro - ./data/web:/web:ro
- ./data/conf/rspamd/dynmaps:/dynmaps:ro - ./data/conf/rspamd/dynmaps:/dynmaps:ro
- ./data/dkim/:/shared/dkim/ - ./data/dkim/:/shared/dkim/
environment:
- DBNAME=${DBNAME}
- DBUSER=${DBUSER}
- DBPASS=${DBPASS}
restart: always restart: always
networks: networks:
mailcow-network: mailcow-network: