-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathcommon.yaml
163 lines (154 loc) · 5.19 KB
/
common.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
daskhub:
jupyterhub:
scheduling:
corePods:
nodeAffinity:
matchNodePurpose: require
singleuser:
image:
pullPolicy: 'Always'
initContainers:
- name: volume-mount-hack
image: busybox
command: ["sh", "-c", "id && chown 1000:1000 /home/jovyan && ls -lhd /home/jovyan"]
securityContext:
runAsUser: 0
volumeMounts:
- name: home
mountPath: /home/jovyan
subPath: "uscentral1b/{username}"
extraEnv:
# Scratch storage within the cluster
PANGEO_SCRATCH_PREFIX: "gs://pangeo-scratch"
# MLFlow configuration
MLFLOW_TRACKING_URI: "http://mlflow"
storage:
type: static
static:
pvcName: home-nfs
subPath: "uscentral1b/{username}"
cloudMetadata:
enabled: true
prePuller:
continuous:
enabled: false
hub:
resources:
requests:
cpu: "0.25"
memory: 0.5Gi
limits:
cpu: "1.25"
memory: 1Gi
services:
mlflow:
admin: True
url: http://mlflow
extraConfig:
administrators: |
c.Authenticator.admin_users = ["TomAugspurger"]
image_pulls: |
c.KubeSpawner.start_timeout = 60 * 10 # 10-minute timeout for large image pulls
profile_list: |
c.KubeSpawner.profile_list = [
{
'display_name': 'Small (1 GB - 4 GB)',
'default': 'True',
'kubespawner_override': {
'cpu_limit': 2,
'cpu_guarantee': 0.3,
'mem_limit': '4G',
'mem_guarantee': '1G',
}
},
{
'display_name': 'Medium (4 GB - 8G GB)',
'kubespawner_override': {
'cpu_limit': 2,
'cpu_guarantee': 1,
'mem_limit': '8G',
'mem_guarantee': '4G',
}
},
{
'display_name': 'Large (12 GB - 16 GB)',
'kubespawner_override': {
'cpu_limit': 4,
'cpu_guarantee': 1,
'mem_limit': '16G',
'mem_guarantee': '12G',
}
},
{
'display_name': 'ML Image - Large (12 GB - 16 GB)',
'description': "https://github.com/pangeo-data/pangeo-docker-images/tree/master/ml-notebook",
'kubespawner_override': {
'image': 'pangeo/ml-notebook:master',
'cpu_limit': 2,
'cpu_guarantee': 1,
'mem_limit': '16G',
'mem_guarantee': '12G',
}
},
]
customPodHook: |
c.JupyterHub.template_paths = ['/usr/local/share/jupyterhub/custom_templates/']
c.JupyterHub.template_vars = {
'pangeo_hub_title': 'Pangeo Cloud',
'pangeo_hub_subtitle': 'us-central1-b.gcp.pangeo.io',
'pangeo_welcome': """Welcome to Pangeo Cloud. This hub lives in Google Cloud region <code>us-central1-b</code>. For information and signup instructions, please visit the <a href="http://pangeo.io/cloud.html">Pangeo Cloud Website</a>.""",
}
extraVolumes:
- name: custom-templates
gitRepo:
repository: "https://github.com/pangeo-data/pangeo-custom-jupyterhub-templates.git"
revision: "39962614b3df4ca86efb29712f7e67c51308d25b"
extraVolumeMounts:
- mountPath: /usr/local/share/jupyterhub/custom_templates
name: custom-templates
subPath: "pangeo-custom-jupyterhub-templates/templates"
- mountPath: /usr/local/share/jupyterhub/static/extra-assets
name: custom-templates
subPath: "pangeo-custom-jupyterhub-templates/extra-assets"
extraEnv:
OAUTH2_AUTHORIZE_URL: "https://pangeo.auth0.com/authorize"
OAUTH2_TOKEN_URL: "https://pangeo.auth0.com/oauth/token"
OAUTH_CALLBACK_URL: "https://staging.us-central1-b.gcp.pangeo.io/hub/oauth_callback"
auth:
type: custom
custom:
className: oauthenticator.generic.GenericOAuthenticator
config:
login_service: "Pangeo"
token_url: https://pangeo.auth0.com/oauth/token
userdata_url: https://pangeo.auth0.com/oauth/userinfo
userdata_method: GET
username_key: nickname
scope:
- openid
- profile
- email
admin:
access: true
users:
- jhamman
- rabernat
- TomAugspurger
- scottyhq
dask-gateway:
gateway:
backend:
worker:
extraPodConfig:
tolerations:
- key: "cloud.google.com/gke-preemptible"
operator: "Equal"
value: "true"
effect: "NoSchedule"
homeDirectories:
nfs:
enabled: true
serverPath: "/homes"
# Output from `gcloud filestore instances describe pangeo-uscentral1b --zone=us-central1-b`
serverIP: 10.126.142.50
serverName: home