Skip to main content

☑️ Ensure workload has a configured `owner` label

An owner label is great not only for financial ownership but also useful for operational ownership. Consider adding an owner label to your workload with the name, email alias or Slack channel of the team responsible for the service. This will make it easier to alert the relevant team or team member when necessary.

tip

FYI

Labels' keys and values are case-sensitive!

Targeted objects by this rule (types of kind): Deployment / Pod / DaemonSet / StatefulSet / ReplicaSet / CronJob / Job

Complexity: easy (What does this mean?)

Policy as code identifier: WORKLOAD_MISSING_LABEL_OWNER_VALUE


This rule will fail

If the owner key is missing from the labels section

metadata:
labels:
env: prod

Rule output in the CLI

$ datree test *.yaml

>> File: failExample.yaml
❌ Ensure workload has a configured `owner` label [1 occurrence]
💡 Missing label object `owner` - add a proper owner label to know which person/team to ping when needed

How to fix this failure

metadata:
labels:
env: prod
owner: yoda-at-datree.io

Read more