Skip to main content
The CockroachDB operator provides abstractions that simplify cluster deployment and node initialization:
  • A default pod specification is used for the CockroachDB Kubernetes pod.
  • The values.yaml configuration maps to a subset of cockroach start flags when CockroachDB is initialized.
This page describes configuration options that allow advanced users to manually override pod template metadata and 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 CockroachDB operator. Cockroach Labs strongly recommends testing these configurations in a non-production environment first.

Override the default pod

The cockroachdb.crdbCluster.podTemplate field allows you to override the default pod metadata and specification configured by the CockroachDB operator. 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 start command, their values overriding any matching flags in the command.
  • Omitted flags are removed from the cockroach start command if they were present.