Skip to content

Commit

Permalink
settings/syntax: Describe effect of %variables better
Browse files Browse the repository at this point in the history
  • Loading branch information
cmouse committed Jan 2, 2025
1 parent 842a8ce commit 6df3f4d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions docs/core/settings/syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,9 @@ read immediately whenever parsing the configuration file, so if it changes
afterwards it requires a configuration reload to see the changes. This
functionality is especially useful for reading SSL certificates and keys.

If you use `%{variables}` in file names, these will be expanded by target
process and not config process, which can cause problems with permissions.

## Variable Expansion

It's possible to refer to other earlier settings as `$SET:name`.
Expand All @@ -436,6 +439,8 @@ However, you must be careful with the ordering of these in the configuration
file, because the `$SET:variables` are expanded immediately while parsing the
config file and they're not updated later.

See also [[link,settings_variables]].

## Environment Variables

It is possible use `$ENV:name` to expand values from environment.
Expand All @@ -447,3 +452,7 @@ Note that these are also Case Sensitive.

These can also be used for external config files, but you need to list them in
[[setting,import_environment]] so that processes can see them.

If you use `${env:}` instead of `$ENV`, this will cause the environment variable(s) to be
evaluated later. This can cause problems with files since config process cannot open
them anymore. It is recommended to use `$ENV` instead when possible.

0 comments on commit 6df3f4d

Please sign in to comment.