Skip to content

Commit 1374d6d

Browse files
committed
Add tmp emptydir mounting
1 parent 2e3f2a0 commit 1374d6d

File tree

3 files changed

+21
-0
lines changed

3 files changed

+21
-0
lines changed

bindata/assets/kube-apiserver/pod.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ spec:
1919
volumeMounts:
2020
- mountPath: /var/log/kube-apiserver
2121
name: audit-dir
22+
- mountPath: /tmp
23+
name: tmp-dir
2224
command: ['/usr/bin/timeout', '{{.SetupContainerTimeoutDuration}}', '/bin/bash', '-ec']
2325
args:
2426
- |
@@ -60,6 +62,7 @@ spec:
6062
# We cannot hold the lock from the init container to the main container. We release it here. There is no risk, at this point we know we are safe.
6163
flock -u "${LOCK_FD}"
6264
securityContext:
65+
readOnlyRootFilesystem: true
6366
privileged: true
6467
resources:
6568
requests:
@@ -98,6 +101,8 @@ spec:
98101
name: cert-dir
99102
- mountPath: /var/log/kube-apiserver
100103
name: audit-dir
104+
- mountPath: /tmp
105+
name: tmp-dir
101106
livenessProbe:
102107
httpGet:
103108
scheme: HTTPS
@@ -177,6 +182,8 @@ spec:
177182
name: resource-dir
178183
- mountPath: /etc/kubernetes/static-pod-certs
179184
name: cert-dir
185+
- mountPath: /tmp
186+
name: tmp-dir
180187
- name: kube-apiserver-cert-regeneration-controller
181188
env:
182189
- name: POD_NAMESPACE
@@ -202,6 +209,8 @@ spec:
202209
volumeMounts:
203210
- mountPath: /etc/kubernetes/static-pod-resources
204211
name: resource-dir
212+
- mountPath: /tmp
213+
name: tmp-dir
205214
- name: kube-apiserver-insecure-readyz
206215
image: {{.OperatorImage}}
207216
imagePullPolicy: IfNotPresent
@@ -248,6 +257,8 @@ spec:
248257
name: resource-dir
249258
- mountPath: /etc/kubernetes/static-pod-certs
250259
name: cert-dir
260+
- mountPath: /tmp
261+
name: tmp-dir
251262
ports:
252263
- name: check-endpoints
253264
hostPort: 17697
@@ -288,3 +299,5 @@ spec:
288299
- hostPath:
289300
path: /var/log/kube-apiserver
290301
name: audit-dir
302+
- emptyDir: {}
303+
name: tmp-dir

bindata/bootkube/bootstrap-manifests/kube-apiserver-pod.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,8 @@ spec:
6969
name: logs
7070
- mountPath: /var/log/kube-apiserver
7171
name: audit-dir
72+
- mountPath: /tmp
73+
name: tmp-dir
7274
livenessProbe:
7375
httpGet:
7476
scheme: HTTPS
@@ -142,3 +144,5 @@ spec:
142144
- hostPath:
143145
path: /var/log/kube-apiserver
144146
name: audit-dir
147+
- emptyDir: {}
148+
name: tmp-dir

manifests/0000_20_kube-apiserver-operator_06_deployment.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,8 @@ spec:
5959
- mountPath: /var/run/secrets/kubernetes.io/serviceaccount
6060
name: kube-api-access
6161
readOnly: true
62+
- mountPath: /tmp
63+
name: tmp-dir
6264
env:
6365
- name: IMAGE
6466
value: quay.io/openshift/origin-hyperkube:v4.0
@@ -99,6 +101,8 @@ spec:
99101
apiVersion: v1
100102
fieldPath: metadata.namespace
101103
path: namespace
104+
- name: tmp-dir
105+
emptyDir: {}
102106
nodeSelector:
103107
node-role.kubernetes.io/master: ""
104108
priorityClassName: "system-cluster-critical"

0 commit comments

Comments
 (0)