- A default pod specification is used for the CockroachDB Kubernetes pod.
- The
values.yamlconfiguration maps to a subset ofcockroach startflags when CockroachDB is initialized.
cockroach start flags as needed for deployment.
The CockroachDB operator is in .
This page describes advanced configurations that override the supported default templates used by the . Cockroach Labs strongly recommends testing these configurations in a non-production environment first.
Override the default pod
Thecockroachdb.crdbCluster.podTemplate field allows you to override the default pod metadata and specification configured by the . The values in this field are merged with the default pod specification, where settings in podTemplate override any values in the default.
The podTemplate field includes a containers field that specifies the container name and image that the template is applied to. By default, this resolves to the cockroachdb container name and can be excluded from modifications to the CockroachDB pod template YAML. If needed, you can provide specific images for the containers and initContainers. For example, the following podTemplate configuration specifies a custom init container:
Override the default cockroach start flags
The cockroachdb.crdbCluster.startFlags field allows you to customize the used when initializing the CockroachDB cluster.
Within this field, you can specify flags to upsert and flags to omit:
- Upserted flags are added to the
cockroach startcommand, their values overriding any matching flags in the command. - Omitted flags are removed from the
cockroach startcommand if they were present.

