Skip to content

[nmfs-openscapes] add shared-public directory for staging and prod #6206

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 13, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions config/clusters/nmfs-openscapes/prod.values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,38 @@ jupyterhub:
extraEnv:
SCRATCH_BUCKET: s3://nmfs-openscapes-scratch/$(JUPYTERHUB_USER)
PERSISTENT_BUCKET: s3://nmfs-openscapes-persistent/$(JUPYTERHUB_USER)
storage:
extraVolumeMounts:
# A shared folder readable & writeable by everyone
- name: home
mountPath: /home/jovyan/shared-public
subPath: _shared-public
readOnly: false
- name: home
mountPath: /home/jovyan/shared
subPath: _shared
readOnly: true
initContainers:
- name: volume-mount-ownership-fix
image: busybox:1.36.1
command:
- sh
- -c
- id && chown 1000:1000 /home/jovyan /home/jovyan/shared /home/jovyan/shared-public && ls -lhd /home/jovyan
securityContext:
runAsUser: 0
volumeMounts:
- name: home
mountPath: /home/jovyan
subPath: '{escaped_username}'
# Mounted without readonly attribute here,
# so we can chown it appropriately
- name: home
mountPath: /home/jovyan/shared
subPath: _shared
- name: home
mountPath: /home/jovyan/shared-public
subPath: _shared-public
hub:
config:
JupyterHub:
Expand Down
32 changes: 32 additions & 0 deletions config/clusters/nmfs-openscapes/staging.values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,38 @@ jupyterhub:
extraEnv:
SCRATCH_BUCKET: s3://nmfs-openscapes-scratch-staging/$(JUPYTERHUB_USER)
PERSISTENT_BUCKET: s3://nmfs-openscapes-persistent-staging/$(JUPYTERHUB_USER)
storage:
extraVolumeMounts:
# A shared folder readable & writeable by everyone
- name: home
mountPath: /home/jovyan/shared-public
subPath: _shared-public
readOnly: false
- name: home
mountPath: /home/jovyan/shared
subPath: _shared
readOnly: true
initContainers:
- name: volume-mount-ownership-fix
image: busybox:1.36.1
command:
- sh
- -c
- id && chown 1000:1000 /home/jovyan /home/jovyan/shared /home/jovyan/shared-public && ls -lhd /home/jovyan
securityContext:
runAsUser: 0
volumeMounts:
- name: home
mountPath: /home/jovyan
subPath: '{escaped_username}'
# Mounted without readonly attribute here,
# so we can chown it appropriately
- name: home
mountPath: /home/jovyan/shared
subPath: _shared
- name: home
mountPath: /home/jovyan/shared-public
subPath: _shared-public
hub:
config:
JupyterHub:
Expand Down
Loading