Skip to content
Snippets Groups Projects
Unverified Commit e7d2135c authored by Haoyu Sun's avatar Haoyu Sun
Browse files

replace deprecated "app" label selector by "app.kubernetes.io/name" in

documents and examples
parent 55209008
No related branches found
No related tags found
No related merge requests found
...@@ -575,7 +575,7 @@ local kp = (import 'kube-prometheus/main.libsonnet') + { ...@@ -575,7 +575,7 @@ local kp = (import 'kube-prometheus/main.libsonnet') + {
], ],
selector: { selector: {
matchLabels: { matchLabels: {
app: 'myapp', 'app.kubernetes.io/name': 'myapp',
}, },
}, },
}, },
......
...@@ -24,7 +24,7 @@ local kp = (import 'kube-prometheus/main.libsonnet') + { ...@@ -24,7 +24,7 @@ local kp = (import 'kube-prometheus/main.libsonnet') + {
], ],
selector: { selector: {
matchLabels: { matchLabels: {
app: 'myapp', 'app.kubernetes.io/name': 'myapp',
}, },
}, },
}, },
......
...@@ -19,4 +19,4 @@ spec: ...@@ -19,4 +19,4 @@ spec:
- logging - logging
selector: selector:
matchLabels: matchLabels:
app: myapp app.kubernetes.io/name: myapp
\ No newline at end of file \ No newline at end of file
...@@ -7,7 +7,7 @@ metadata: ...@@ -7,7 +7,7 @@ metadata:
namespace: default namespace: default
spec: spec:
selector: selector:
app: example-app app.kubernetes.io/name: example-app
ports: ports:
- name: web - name: web
protocol: TCP protocol: TCP
...@@ -22,13 +22,13 @@ metadata: ...@@ -22,13 +22,13 @@ metadata:
spec: spec:
selector: selector:
matchLabels: matchLabels:
app: example-app app.kubernetes.io/name: example-app
version: 1.1.3 version: 1.1.3
replicas: 4 replicas: 4
template: template:
metadata: metadata:
labels: labels:
app: example-app app.kubernetes.io/name: example-app
version: 1.1.3 version: 1.1.3
spec: spec:
containers: containers:
......
...@@ -81,7 +81,7 @@ ...@@ -81,7 +81,7 @@
}, },
deployment: deployment:
local podLabels = { app: 'ksm-autoscaler' }; local podLabels = { 'app.kubernetes.io/name': 'ksm-autoscaler' };
local c = { local c = {
name: 'ksm-autoscaler', name: 'ksm-autoscaler',
image: $.values.clusterVerticalAutoscaler.image, image: $.values.clusterVerticalAutoscaler.image,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment