Configuration and environment overrides
The cluster definition also supports overriding configuration properties and environment variables, either per role or per role group, where the more specific override (role group) has precedence over the less specific one (role).
Overriding certain properties which are set by operator (such as the ports) can interfere with the operator and can lead to problems. |
Configuration properties
For a role or role group, at the same level of config
, you can specify: configOverrides
for the zoo.cfg
. For example, if you want to set the 4lw.commands.whitelist
to allow the ruok
administrative command, it can be configured in the ZookeeperCluster
resource like so:
servers:
roleGroups:
default:
configOverrides:
zoo.cfg:
4lw.commands.whitelist: "srvr, ruok"
replicas: 1
Just as for the config
, it is possible to specify this at role level as well:
routers:
configOverrides:
zoo.cfg:
4lw.commands.whitelist: "srvr, ruok"
roleGroups:
default:
replicas: 1
All override property values must be strings.
For a full list of configuration options we refer to the Apache ZooKeeper Configuration Reference.