1
- # Copyright 2021 Google LLC
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # http://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
-
15
1
apiVersion : apps/v1
16
2
kind : Deployment
17
3
metadata :
18
- name : digester-controller-manager
19
- namespace : digester-system
20
4
labels :
21
5
control-plane : controller-manager
22
6
digester/operation : webhook
23
7
digester/system : " yes"
8
+ name : digester-controller-manager
9
+ namespace : digester-system
24
10
spec :
25
- replicas : 3 # kpt-set: ${replicas}
11
+ replicas : 3
26
12
selector :
27
13
matchLabels :
28
14
control-plane : controller-manager
29
15
digester/operation : webhook
30
16
digester/system : " yes"
31
17
template :
32
18
metadata :
19
+ annotations :
20
+ prometheus.io/port : " 8888"
33
21
labels :
34
22
control-plane : controller-manager
35
23
digester/operation : webhook
36
24
digester/system : " yes"
37
- annotations :
38
- prometheus.io/port : " 8888" # kpt-set: ${metrics-port}
39
25
spec :
40
- serviceAccountName : digester-admin
41
- nodeSelector :
42
- kubernetes.io/os : linux
43
26
containers :
44
- - name : manager
45
- image : k8s-digester # kpt-set: ${image}
46
- args :
27
+ - args :
47
28
- webhook
48
- - --cert-dir=/certs # kpt-set: --cert-dir=${cert-dir}
49
- - --disable-cert-rotation=false # kpt-set: --disable-cert-rotation=${disable-cert-rotation}
50
- - --dry-run=false # kpt-set: --dry-run=${dry-run}
51
- - --health-addr=:9090 # kpt-set: --health-addr=:${health-port}
52
- - --metrics-addr=:8888 # kpt-set: --metrics-addr=:${metrics-port}
53
- - --offline=false # kpt-set: --offline=${offline}
54
- - --port=8443 # kpt-set: --port=${port}
55
- ports :
56
- - name : webhook-server
57
- protocol : TCP
58
- containerPort : 8443 # kpt-set: ${port}
59
- - name : metrics
60
- protocol : TCP
61
- containerPort : 8888 # kpt-set: ${metrics-port}
62
- - name : healthz
63
- protocol : TCP
64
- containerPort : 9090 # kpt-set: ${health-port}
29
+ - --cert-dir=/certs
30
+ - --disable-cert-rotation=false
31
+ - --dry-run=false
32
+ - --health-addr=:9090
33
+ - --metrics-addr=:8888
34
+ - --offline=false
35
+ - --port=8443
65
36
env :
66
37
- name : DEBUG
67
- value : " false" # kpt-set: ${debug}
38
+ value : " false"
68
39
- name : POD_NAME
69
40
valueFrom :
70
41
fieldRef :
@@ -74,23 +45,31 @@ spec:
74
45
fieldRef :
75
46
apiVersion : v1
76
47
fieldPath : metadata.namespace
77
- resources :
78
- requests :
79
- cpu : 100m # kpt-set: ${request-cpu}
80
- ephemeral-storage : 256Mi # kpt-set: ${request-ephemeral-storage}
81
- memory : 256Mi # kpt-set: ${request-memory}
82
- volumeMounts :
83
- - name : cert
84
- readOnly : true
85
- mountPath : /certs # kpt-set: ${cert-dir}
48
+ image : ghcr.io/google/k8s-digester:v0.1.16@sha256:56c34bd2f2b37c81fac97358d8c06deed13f9998477cdc8583c6d69c8cfad999
86
49
livenessProbe :
87
50
httpGet :
88
- port : healthz
89
51
path : /healthz
52
+ port : healthz
53
+ name : manager
54
+ ports :
55
+ - containerPort : 8443
56
+ name : webhook-server
57
+ protocol : TCP
58
+ - containerPort : 8888
59
+ name : metrics
60
+ protocol : TCP
61
+ - containerPort : 9090
62
+ name : healthz
63
+ protocol : TCP
90
64
readinessProbe :
91
65
httpGet :
92
- port : healthz
93
66
path : /readyz
67
+ port : healthz
68
+ resources :
69
+ requests :
70
+ cpu : 100m
71
+ ephemeral-storage : 256Mi
72
+ memory : 256Mi
94
73
securityContext :
95
74
allowPrivilegeEscalation : false
96
75
capabilities :
@@ -100,6 +79,13 @@ spec:
100
79
runAsGroup : 65532
101
80
runAsNonRoot : true
102
81
runAsUser : 65532
82
+ volumeMounts :
83
+ - mountPath : /certs
84
+ name : cert
85
+ readOnly : true
86
+ nodeSelector :
87
+ kubernetes.io/os : linux
88
+ serviceAccountName : digester-admin
103
89
volumes :
104
90
- name : cert
105
91
secret :
0 commit comments