sec context
This commit is contained in:
parent
4960af6b88
commit
bfa8daa7db
1 changed files with 17 additions and 1 deletions
|
|
@ -13,9 +13,25 @@ spec:
|
||||||
labels:
|
labels:
|
||||||
app: hermes-agent
|
app: hermes-agent
|
||||||
spec:
|
spec:
|
||||||
|
initContainers:
|
||||||
|
- name: fix-volume-permissions
|
||||||
|
image: busybox:latest
|
||||||
|
# Run a quick chown to give user 10000 and group 10000 full ownership
|
||||||
|
command: ["sh", "-c", "chown -R 10000:10000 /opt/data"]
|
||||||
|
securityContext:
|
||||||
|
runAsUser: 0 # Must run as root to change permissions
|
||||||
|
runAsNonRoot: false
|
||||||
|
volumeMounts:
|
||||||
|
- name: hermes-data
|
||||||
|
mountPath: /opt/data
|
||||||
containers:
|
containers:
|
||||||
- name: hermes-agent
|
- name: hermes-agent
|
||||||
image: nousresearch/hermes-agent:latest
|
image: nousresearch/hermes-agent:latest
|
||||||
|
securityContext:
|
||||||
|
runAsNonRoot: true
|
||||||
|
runAsUser: 10000
|
||||||
|
runAsGroup: 10000
|
||||||
|
allowPrivilegeEscalation: true
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 8642
|
- containerPort: 8642
|
||||||
command: ["/bin/bash", "-c"]
|
command: ["/bin/bash", "-c"]
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue