Skip to content

Commit

Permalink
[DOC] Clarify the scope of environment variable expansion (#13299) (#…
Browse files Browse the repository at this point in the history
…13312)

Environment variable expansion only works in plugin parameters, not in conditionals.
For more on this limitation see #5115

(cherry picked from commit 096eb7a)
  • Loading branch information
jsvd committed Oct 13, 2021
1 parent a0bdf52 commit 92337af
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/static/configuration.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -726,6 +726,10 @@ environment variable is undefined.
* You can add environment variable references in any plugin option type : string, number, boolean, array, or hash.
* Environment variables are immutable. If you update the environment variable, you'll have to restart Logstash to pick up the updated value.

NOTE: Environment variable references are only supported in plugin configuration, not in {logstash-ref}/event-dependent-configuration.html#conditionals[conditionals]. A workaround for this limitation is to add a new event field with the value
of the environment variable and use that new field in the conditional.


==== Examples

The following examples show you how to use environment variables to set the values of some commonly used
Expand Down

0 comments on commit 92337af

Please sign in to comment.