Labels Guide

This guide describes a set of labels which may be used on Kubernetes objects. It’s considered best practise to adhere to this guide but is in no way required or enforced.

The following labels are recommended to be set on objects of a Commodore component:

From the Kubernetes documentation
Key Description Example

The name of the application


A unique name identifying the instance of an application


The current version of the application (for example a semantic version, revision hash, etc.)


The component within the architecture


The name of a higher level application this one is part of


The tool being used to manage the operation of an application, usually commodore


At the very minimum it’s recommended to set the label on all resources of a component.

Example Deployment
apiVersion: apps/v1
kind: Deployment
  name: steward
  labels: steward steward-cluster v0.2.0 syn commodore
  selector: steward steward-cluster
      labels: steward steward-cluster

Make sure not to set the label on pod resources. This might lead to unnecessary redpeloyments on version changes.

Label Selectors

For some resources it’s necessary to specify label selectors (for example Deployment, Service). In these cases it’s especially important to not have colliding selectors since this might lead to unintended behavior. In general the following labels are recommended to be used in label selectors:

Restricted Labels

The only label that’s restricted and must not be used is the following:

This label is being used by Argo CD to track the objects it’s managing. Using this label for anything else might result in undefined behavior.