Skip to content

Commit

Permalink
Hard code PVC name as efs
Browse files Browse the repository at this point in the history
As we can't use variable in values.yaml
  • Loading branch information
xcompass committed Feb 23, 2024
1 parent ffdb180 commit cdaad3b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
jupyterhub/templates/
jupyterhub/templates/**
5 changes: 5 additions & 0 deletions jupyterhub/templates/_helpers-names.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,11 @@
{{- include "jupyterhub.fullname.dash" . }}exam-api
{{- end }}

{{- /* EFS name */}}
{{- define "jupyterhub.efs.fullname" -}}
{{- include "jupyterhub.fullname.dash" . }}efs
{{- end }}

{{- /*
Cluster wide resources
Expand Down
2 changes: 1 addition & 1 deletion jupyterhub/templates/examapi/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,5 +80,5 @@ spec:
volumes:
- name: jupyterhub-efs
persistentVolumeClaim:
claimName: {{ include "jupyterhub.examapi.fullname" . }}
claimName: efs
{{- end }}
4 changes: 2 additions & 2 deletions jupyterhub/templates/examapi/pv.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: v1
kind: PersistentVolume
metadata:
name: {{ include "jupyterhub.examapi.fullname" . }}
name: {{ include "jupyterhub.efs.fullname" . }}
spec:
capacity:
storage: 5Gi
Expand All @@ -20,7 +20,7 @@ spec:
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: {{ include "jupyterhub.examapi.fullname" . }}
name: efs
spec:
accessModes:
- ReadWriteMany
Expand Down

0 comments on commit cdaad3b

Please sign in to comment.