Skip to content

Commit 541d0ae

Browse files
tjohnson31415njhill
authored andcommitted
deploy: add patch for stricter pod security
Signed-off-by: Travis Johnson <[email protected]>
1 parent d176e16 commit 541d0ae

File tree

2 files changed

+22
-0
lines changed

2 files changed

+22
-0
lines changed

deployment/base/deployment.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ spec:
2323

2424
securityContext:
2525
allowPrivilegeEscalation: false
26+
privileged: false
2627
runAsNonRoot: true
2728
seccompProfile:
2829
type: RuntimeDefault
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
apiVersion: apps/v1
2+
kind: Deployment
3+
metadata:
4+
name: inference-server
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- name: server
10+
env:
11+
# set base directory for caches
12+
- name: HF_HOME
13+
value: /tmp/
14+
securityContext:
15+
readOnlyRootFilesystem: true
16+
volumeMounts:
17+
- name: tmp
18+
mountPath: /tmp
19+
volumes:
20+
- name: tmp
21+
emptyDir: {}

0 commit comments

Comments
 (0)