Skip to content

Commit 08f2c8c

Browse files
authored
Merge pull request #322 from dmvolod/issue-236
✨ Able to run controller inside the container platform with write access to root restrictions
2 parents d01bead + 1495994 commit 08f2c8c

File tree

1 file changed

+23
-5
lines changed

1 file changed

+23
-5
lines changed

config/manager/manager.yaml

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,28 @@ spec:
3030
type: RuntimeDefault
3131
containers:
3232
- args:
33-
- --leader-elect
34-
- "--diagnostics-address=${CAAPH_DIAGNOSTICS_ADDRESS:=:8443}"
35-
- "--insecure-diagnostics=${CAAPH_INSECURE_DIAGNOSTICS:=false}"
36-
- "--sync-period=${CAAPH_SYNC_PERIOD:=10m}"
37-
- "--v=2"
33+
- --leader-elect
34+
- "--diagnostics-address=${CAAPH_DIAGNOSTICS_ADDRESS:=:8443}"
35+
- "--insecure-diagnostics=${CAAPH_INSECURE_DIAGNOSTICS:=false}"
36+
- "--sync-period=${CAAPH_SYNC_PERIOD:=10m}"
37+
- "--v=2"
38+
env:
39+
- name: XDG_DATA_HOME
40+
value: /tmp/xdg/.data
41+
- name: XDG_CONFIG_HOME
42+
value: /tmp/xdg/.config
43+
- name: XDG_STATE_HOME
44+
value: /tmp/xdg/.state
45+
- name: XDG_CACHE_HOME
46+
value: /tmp/xdg/.cache
47+
- name: XDG_CONFIG_DIRS
48+
value: /tmp/xdg
3849
image: controller:latest
3950
imagePullPolicy: Always
4051
name: manager
4152
securityContext:
4253
allowPrivilegeEscalation: false
54+
readOnlyRootFilesystem: true
4355
capabilities:
4456
drop:
4557
- ALL
@@ -65,6 +77,12 @@ spec:
6577
port: healthz
6678
initialDelaySeconds: 10
6779
periodSeconds: 10
80+
volumeMounts:
81+
- mountPath: /tmp
82+
name: tmp
83+
volumes:
84+
- emptyDir: {}
85+
name: tmp
6886
# TODO(user): Configure the resources accordingly based on the project requirements.
6987
# More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
7088
# resources:

0 commit comments

Comments
 (0)