Skip to content
Snippets Groups Projects
values.template.yaml 5.26 KiB
Newer Older
# https://ucsd-prp.gitlab.io/userdocs/development/jupyterhub/
Dung Vu's avatar
Dung Vu committed
hub:
  config:
    CILogonOAuthenticator:
      client_id: cilogon:/client_id/76c3f7eb194ad6ef6c22a92ce1b54d89
      client_secret: t_zrDuJRlJX4LZhUCrk3iPMwG9MKKuveHZMzqINyET3RfidDEvAnkNRHhYC1NiRtShsThwF0cy4vzLNorNw4-Q
      oauth_callback_url: https://csusb-hub-project.nrp-nautilus.io/hub/oauth_callback
Dung Vu's avatar
Dung Vu committed
      username_claim: "email"
      allowed_idps: ["csusb.edu"]
Dung Vu's avatar
Dung Vu committed
    JupyterHub:
      admin_access: true
Dung Vu's avatar
Dung Vu committed
      admin_users: ["dvu@csusb.edu", "000065181@csusb.edu", "youngsu.kim@csusb.edu", "006501270@csusb.edu"]
      authenticator_class: cilogon
      #Restricts access to csusb domains 
      #allowed_idps command may change its funtionality after update 
      #https://github.com/jupyterhub/oauthenticator/issues/494
      allowed_idps: ["csusb.edu"]

# initContainers for custom htmls
  initContainers:
    - name: git-clone-templates
      image: alpine/git
      args:
        - clone
        - --single-branch
        - --branch=main
        - --depth=1
        - --
        - https://gitlab.nrp-nautilus.io/csusb-prp/csusb-jupyterhub-templates.git
        - /etc/jupyterhub/custom
      securityContext:
        runAsUser: 0
      volumeMounts:
        - name: custom-templates
          mountPath: /etc/jupyterhub/custom
  extraVolumes:
    - name: custom-templates
      emptyDir: {}
  extraVolumeMounts:
    - name: custom-templates
      mountPath: /etc/jupyterhub/custom
  extraConfig:
    templates: |
      c.JupyterHub.template_paths = ['/etc/jupyterhub/custom']

# https://github.com/jupyterhub/zero-to-jupyterhub-k8s/issues/1990
  extraFiles:
    image_select_idp:
      mountPath: /usr/local/share/jupyterhub/static/select_idp_cilogon.png

    # Files in /usr/local/etc/jupyterhub/jupyterhub_config.d are
    # automatically loaded in alphabetical order of the final file
    # name when JupyterHub starts.

    # for dynamic resource allocation 
    custom_spawner:
      mountPath: /usr/local/etc/jupyterhub/jupyterhub_config.d/my_spawner.py
    # Custom profiles list for the spawner above
    custom_spawner_profile:
      mountPath: /etc/jupyterhub/custom/my_spawner.html

Dung Vu's avatar
Dung Vu committed
  service:
    type: ClusterIP
    annotations: {}
    ports:
Dung Vu's avatar
Dung Vu committed
    loadBalancerIP:
  deploymentStrategy:
    type: Recreate
  db:
    type: sqlite-pvc
    pvc:
      accessModes:
        - ReadWriteOnce
Dung Vu's avatar
Dung Vu committed
      storageClassName: rook-ceph-block
  resources:
    limits:
      cpu: "2"
Dung Vu's avatar
Dung Vu committed
    requests:
Dung Vu's avatar
Dung Vu committed
  networkPolicy:
    enabled: false
proxy:
  secretToken: "795cb91892686a06560e9532d2b073b4cdbe102e92ea2b25496e3ae76f240c09"
Dung Vu's avatar
Dung Vu committed
  service:
    type: ClusterIP
  chp:
    resources:
      limits:
        cpu: "2"
Dung Vu's avatar
Dung Vu committed
      requests:
Dung Vu's avatar
Dung Vu committed
singleuser:
  extraNodeAffinity:
    required:
      - matchExpressions:
        - 'key': 'topology.kubernetes.io/region'
          'operator': 'In'
          'values': ["us-west"]
        # - 'key': 'nvidia.com/cuda.runtime.major'
        #   'operator': 'In'
        #   'values': ["11"]   
        # - 'key': 'nvidia.com/cuda.runtime.minor'
        #   'operator': 'In'
        #   'values': ["4"] 
        # - 'key': 'kubernetes.io/hostname'
        #   'operator': 'In' 
        #   'values': ['fiona8-0.calit2.uci.edu','fiona8-1.calit2.uci.edu','fiona8-2.calit2.uci.edu','fiona8-3.calit2.uci.edu']
Dung Vu's avatar
Dung Vu committed
  cloudMetadata:
    blockWithIptables: false
  networkPolicy:
    enabled: false
  storage:
    type: dynamic
    extraLabels: {}
    # extraVolumes: []
    # extraVolumeMounts: []
    capacity: 5Gi
Dung Vu's avatar
Dung Vu committed
    homeMountPath: /home/jovyan
    dynamic:
      storageClass: rook-ceph-block
      pvcNameTemplate: claim-{username}{servername}
      volumeNameTemplate: volume-{username}{servername}
      storageAccessModes: [ReadWriteOnce]
    # extraVolumes:
    #   - name: csusb-hub-project-share
    #     persistentVolumeClaim:
    #       claimName: csusb-hub-project-share
    # extraVolumeMounts:
    #   - name: csusb-hub-project-share
    #     mountPath: /home/jovyan/shared        
Dung Vu's avatar
Dung Vu committed
  image:
    name: localhost:30081/prp/jupyter-stack/prp
    tag: latest
  startTimeout: 600
  cpu:
Dung Vu's avatar
Dung Vu committed
  memory:
Dung Vu's avatar
Dung Vu committed
  extraResource:
    limits: {}
    guarantees: {}
  cmd: jupyterhub-singleuser
Dung Vu's avatar
Dung Vu committed
  defaultUrl: "/lab"

  # This list is overriden by extraFile
Dung Vu's avatar
Dung Vu committed
  profileList:
  - display_name: Stack Minimal
    kubespawner_override:
      image_spec: localhost:30081/prp/jupyter-stack/minimal
      # extra_resource_limits:
      #   nvidia.com/gpu: {}
    # default: True
  - display_name: Stack Minimal no GPU
Dung Vu's avatar
Dung Vu committed
    kubespawner_override:
      image_spec: localhost:30081/prp/jupyter-stack/minimal
      # extra_resource_limits:
        # nvidia.com/gpu: "1"
    # default: True
  
Dung Vu's avatar
Dung Vu committed
scheduling:
  userScheduler:
    enabled: false
# prePuller relates to the hook|continuous-image-puller DaemonsSets
prePuller:
  hook:
    enabled: false
  continuous:
    enabled: false

ingress:
  enabled: true
  annotations:
    kubernetes.io/ingress.class: haproxy
  hosts: ["csusb-hub-project.nrp-nautilus.io"]
Dung Vu's avatar
Dung Vu committed
  pathSuffix: ''
  tls:
    - hosts:
      - csusb-hub-project.nrp-nautilus.io
Dung Vu's avatar
Dung Vu committed

cull:
Dung Vu's avatar
Dung Vu committed
  users: false
  removeNamedServers: false
  timeout: 3600
  every: 600
Dung Vu's avatar
Dung Vu committed
  concurrency: 10