I want to configure the service label app.kubernetes.io/part-of: myapp
for the kubernetes discovery in my spring boot admin application.
app.kubernetes.io/part-of
is a recommended label, so I think there should be a way to configure it for the service discovery.
spring:
cloud:
kubernetes:
discovery:
namespace: myspace
all-namespaces: true
service-labels:
'app.kubernetes.io/part-of': myapp
Unfortunately all special characters are removed in the yaml keys, which I notice in the configprops
actuator.
My questions:
Hints:
You can encode it with square brackets
"[app.kubernetes.io/part-of]": myapp