Class ConfigArgsConfigSource
java.lang.Object
io.smallrye.config.common.AbstractConfigSource
io.smallrye.config.common.MapBackedConfigSource
io.smallrye.config.PropertiesConfigSource
org.keycloak.quarkus.runtime.configuration.ConfigArgsConfigSource
- All Implemented Interfaces:
Serializable,org.eclipse.microprofile.config.spi.ConfigSource
public class ConfigArgsConfigSource
extends io.smallrye.config.PropertiesConfigSource
A configuration source for mapping configuration arguments to their corresponding properties so that they can be recognized when building and running the server.
The mapping is based on the system property kc.config.args, where the value is a comma-separated list of
the arguments passed during build or runtime. E.g: "--http-enabled=true,--http-port=8180,--database-vendor=postgres".
Each argument is going to be mapped to its corresponding configuration property by prefixing the key with the MicroProfileConfigProvider.NS_KEYCLOAK namespace.
- See Also:
-
Field Summary
FieldsFields inherited from interface org.eclipse.microprofile.config.spi.ConfigSource
CONFIG_ORDINAL, DEFAULT_ORDINAL -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReads the previously set system property for the originally command.static voidparseConfigArgs(BiConsumer<String, String> cliArgConsumer) static voidsetCliArgs(String[] args) Methods inherited from class io.smallrye.config.common.MapBackedConfigSource
getProperties, getPropertyNamesMethods inherited from class io.smallrye.config.common.AbstractConfigSource
getName, getOrdinal, toString
-
Field Details
-
CLI_ARGS
- See Also:
-
NAME
- See Also:
-
-
Constructor Details
-
ConfigArgsConfigSource
protected ConfigArgsConfigSource()
-
-
Method Details
-
setCliArgs
-
getAllCliArgs
Reads the previously set system property for the originally command. Use the System variable, when you trigger other command executions internally, but need a reference to the actually invoked command.- Returns:
- the invoked command from the CLI, or empty List if not set.
-
getValue
- Specified by:
getValuein interfaceorg.eclipse.microprofile.config.spi.ConfigSource- Overrides:
getValuein classio.smallrye.config.common.MapBackedConfigSource
-
parseConfigArgs
-