The only non-alphanumeric characters that can be in label values are . and -, but if you add
metadata:
labels:
test: this/should/fail
to some object it will still pass.
Trying to apply it yields
invalid: metadata.labels: Invalid value: "this/should/fail": a valid label must be
an empty string or consist of alphanumeric characters, '-', '_' or '.', and must start
and end with an alphanumeric character (e.g. 'MyValue', or 'my_value', or '12345',
regex used for validation is '(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?')
The only non-alphanumeric characters that can be in label values are
.
and-
, but if you addto some object it will still pass.
Trying to apply it yields
Versions: