Skip to content

Commit

Permalink
doc: adding a note about config expressions
Browse files Browse the repository at this point in the history
fix: keycloak#19831

Signed-off-by: Steve Hawkins <shawkins@redhat.com>

Co-authored-by: Václav Muzikář <vaclav@muzikari.cz>
  • Loading branch information
shawkins and vmuzikar committed Dec 5, 2023
1 parent 31b7c9d commit 782ed8f
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion docs/guides/server/configuration.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -143,10 +143,17 @@ You can use only a https://github.com/keycloak/keycloak/blob/main/quarkus/runtim

. Use the `[-cf|--config-file]` command line parameter to include that file.

Similarly, you can also store Quarkus properies in a Java KeyStore.
Similarly, you can also store Quarkus properties in a Java KeyStore.

Note that some Quarkus properties are already mapped in the {project_name} configuration, such as `quarkus.http.port` and similar essential properties. If the property is used by Keycloak, defining that property key in `quarkus.properties` has no effect. The Keycloak configuration value takes precedence over the Quarkus property value.

=== Using special characters in values

Keycloak depends upon Quarkus / MicroProfile for processing configuration values. Be aware that value expressions are supported - for example `$\{some_key}`, will evaluate to the value of some_key.

To disable expression evaluation, the `\` character is used as an escape character. In particular it must be used to escape the usage of `$` characters when they appear to define a expression or are repeated. For example if you want the configuration value `my$$password`, use `my\$\$password` instead. Note that the `\` character requires additional escaping or quoting when using most unix shells, or when it appears in properties files.
For example bash single quotes will preserve the single backslash `--db-password='my\$\$password'`, or with bash double quotes you will need an additional backslash `--db-password="my\\$\\$password"`. Similarly in a properties file backslash characters must themselves be escaped: `kc.db-password=my\\$\\$password`

== Starting {project_name}
You can start {project_name} in `development mode` or `production mode`. Each mode offers different defaults for the intended environment.

Expand Down

0 comments on commit 782ed8f

Please sign in to comment.