Commit 8a5e2fd7 authored by Philippe Pepiot's avatar Philippe Pepiot
Browse files

[kubernetes] Fix owner and mode of cwclientlibrc

Kubernetes can set a mode using "defaultMode" but cannot mount the file with
other uid than root.
So we have to mount the secret and copy it with good mode and ower in
/etc/cubicweb.d/fresh/cwclientlibrc...
parent c8e6db0a7613
......@@ -64,8 +64,11 @@ spec:
- name: static
mountPath: /etc/cubicweb.d/fresh/data
- name: cwclientlibrc
mountPath: /etc/cubicweb.d/fresh/cwclientlibrc
subPath: cwclientlibrc
mountPath: /secret
command: [
"/bin/sh", "-c",
"install -m 400 /secret/cwclientlibrc /etc/cubicweb.d/fresh/cwclientlibrc && exec /entrypoint.sh start"
]
resources:
requests:
cpu: 500m
......@@ -128,9 +131,11 @@ spec:
name: fresh-env
volumeMounts:
- name: cwclientlibrc
mountPath: /etc/cubicweb.d/fresh/cwclientlibrc
subPath: cwclientlibrc
command: ["cubicweb-ctl", "scheduler", "fresh"]
mountPath: /secret
command: [
"/bin/sh", "-c",
"install -m 400 /secret/cwclientlibrc /etc/cubicweb.d/fresh/cwclientlibrc && exec cubicweb-ctl sheduler fresh"
]
resources:
requests:
cpu: 100m
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment