Skip to content

Commit 57e9389

Browse files
committed
Refactor existing environment variables in standalone image to prevent accidental changes to crucial configuration options
1 parent 8533e28 commit 57e9389

File tree

3 files changed

+21
-3
lines changed

3 files changed

+21
-3
lines changed

docker/config.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,14 @@ parameters:
55
framework:
66
secret: '%kernel_secret%'
77

8+
messenger:
9+
transports:
10+
async:
11+
dsn: 'doctrine://default?auto_setup=0'
12+
813
trusted_proxies: '%env(TRUSTED_PROXIES)%'
914
trusted_headers: ['x-forwarded-for', 'x-forwarded-host', 'x-forwarded-port', 'x-forwarded-prefix', 'x-forwarded-proto']
15+
16+
doctrine:
17+
dbal:
18+
url: 'postgresql://dirigent@127.0.0.1:5432/dirigent?serverVersion=16&charset=utf8'

docker/env.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,12 @@
22

33
return [
44
'APP_ENV' => 'prod',
5-
'DATABASE_URL' => 'postgresql://dirigent@127.0.0.1:5432/dirigent?serverVersion=16&charset=utf8',
65
'DIRIGENT_IMAGE' => '1',
6+
'SYMFONY_DOTENV_PATH' => './.env.dirigent',
7+
78
'GITHUB_TOKEN' => '',
89
'KERNEL_SECRET_FILE' => '/srv/config/secrets/kernel_secret',
910
'MAILER_DSN' => 'null://null',
10-
'MESSENGER_TRANSPORT_DSN' => 'doctrine://default?auto_setup=0',
1111
'SENTRY_DSN' => '',
12-
'SYMFONY_DOTENV_PATH' => './.env.dirigent',
1312
'TRUSTED_PROXIES' => '',
1413
];

docs/installation/docker-standalone.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,16 @@ dirigent:
6565

6666
For a complete list of configuration options, see the [Configuration Reference][docs-configuration-reference].
6767

68+
### Environment variables
69+
70+
- `DECRYPTION_KEY` / `DECRYPTION_KEY_FILE`
71+
- `ENCRYPTION_KEY` / `ENCRYPTION_KEY_FILE`
72+
- `GITHUB_TOKEN`
73+
- `KERNEL_SECRET` / `KERNEL_SECRET_FILE`
74+
- `MAILER_DSN`
75+
- `SENTRY_DSN`
76+
- `TRUSTED_PROXIES`
77+
6878
## Running the image
6979

7080
After following the steps above you're ready to boot the image, so run the Docker command to start your

0 commit comments

Comments
 (0)