Skip to content

Commit

Permalink
fix: volume permission in kubernetes setup (#1747)
Browse files Browse the repository at this point in the history
* fix: volume permission in torchserve kubernetes

Signed-off-by: jagadeesh <[email protected]>

* Trigger Build

* Trigger Build

Signed-off-by: jagadeesh <[email protected]>
Co-authored-by: Geeta Chauhan <[email protected]>
Co-authored-by: Aaqib <[email protected]>
Co-authored-by: Mark Saroufim <[email protected]>
  • Loading branch information
4 people authored Oct 3, 2022
1 parent 6b4dc84 commit 23a7671
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 20 deletions.
15 changes: 1 addition & 14 deletions kubernetes/Helm/templates/torchserve.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,17 +42,7 @@ spec:
volumes:
- name: persistent-storage
persistentVolumeClaim:
claimName: model-store-claim
initContainers:
- name: volume-ownership
image: alpine:3
command:
- chown
- root:{{ .Values.securityContext.groupId }}
- {{ .Values.torchserve.pvd_mount }}
volumeMounts:
- name: persistent-storage
mountPath: {{ .Values.torchserve.pvd_mount }}
claimName: {{ .Values.persistentVolume.name }}
containers:
- name: torchserve
image: {{ .Values.torchserve_image }}
Expand All @@ -73,6 +63,3 @@ spec:
cpu: {{ .Values.torchserve.n_cpu }}
memory: {{ .Values.torchserve.memory_limit }}
nvidia.com/gpu: {{ .Values.torchserve.n_gpu }}
requests:
cpu: {{ .Values.torchserve.n_cpu }}
memory: {{ .Values.torchserve.memory_request }}
11 changes: 5 additions & 6 deletions kubernetes/Helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,12 @@ torchserve:
inference_port: 8080
metrics_port: 8082
pvd_mount: /home/model-server/shared/
n_gpu: 1
n_cpu: 1
memory_limit: 4Gi
memory_request: 1Gi
n_gpu: 4
n_cpu: 16
memory_limit: 32Gi

deployment:
replicas: 1

persitant_volume:
size: 1Gi
persistentVolume:
name: efs-claim

0 comments on commit 23a7671

Please sign in to comment.