Skip to content
This repository was archived by the owner on Nov 10, 2022. It is now read-only.

Commit c4fab37

Browse files
committed
Fixup exposing ENVs
1 parent c97fb66 commit c4fab37

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

docker/config.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
$dbUsername = getenv('DB_USERNAME');
3131
$dbPassword = getenv('DB_PASSWORD');
3232

33-
eval(<<<PHP
33+
$dataConfig = <<<PHP
3434
class Config {
3535
3636
// ------------------------------------------------------------------------
@@ -39,7 +39,7 @@ class Config {
3939
4040
const BASE_URL = '$baseUrl';
4141
const LANGUAGE = 'french';
42-
const DEBUG_MODE = FALSE;
42+
const DEBUG_MODE = false;
4343
4444
// ------------------------------------------------------------------------
4545
// DATABASE SETTINGS
@@ -63,5 +63,7 @@ class Config {
6363
6464
/* End of file config.php */
6565
/* Location: ./config.php */
66-
PHP
67-
);
66+
PHP;
67+
68+
eval($dataConfig);
69+
unset($dataConfig, $baseUrl, $dbHost, $dbName, $dbUsername, $dbPassword);

docker/horust/services/fpm.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,4 @@ wait = "10s"
2424

2525
[environment]
2626
keep-env = false
27+
re-export = ["BASE_URL", "DB_HOST", "DB_NAME", "DB_USERNAME", "DB_PASSWORD"]

docker/php-fpm-www-pool.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ slowlog = /dev/stdout
2424
catch_workers_output = yes
2525
decorate_workers_output = yes
2626

27-
clear_env = yes
27+
clear_env = no
2828
security.limit_extensions = .php
2929

3030
php_flag[display_errors] = on

0 commit comments

Comments
 (0)