Skip to content

Commit ecc8e44

Browse files
committed
minor #16383 Note that env vars are not always compatible with options (melkamar)
This PR was submitted for the 6.0 branch but it was merged into the 5.4 branch instead. Discussion ---------- Note that env vars are not always compatible with options There are cases where environment variables cannot be used in place of regular configuration options. This commit makes the limitation explicit. From symfony/symfony#39902 <!-- If your pull request fixes a BUG, use the oldest maintained branch that contains the bug (see https://symfony.com/releases for the list of maintained branches). If your pull request documents a NEW FEATURE, use the same Symfony branch where the feature was introduced (and `6.x` for features of unreleased versions). --> Commits ------- 6b73dda Note that env vars are not always compatible with options
2 parents bfc68c1 + 6b73dda commit ecc8e44

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

configuration.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -602,6 +602,10 @@ You can reference environment variables using the special syntax
602602
``%env(ENV_VAR_NAME)%``. The values of these options are resolved at runtime
603603
(only once per request, to not impact performance).
604604

605+
Note that not all config options are compatible with environment variables. There are
606+
`cases <https://github.com/symfony/symfony/issues/39902>`_ which may require refactoring
607+
the config definition in order to work with environment variables.
608+
605609
This example shows how you could configure the database connection using an env var:
606610

607611
.. configuration-block::

0 commit comments

Comments
 (0)