Annotations on binderhub pods
See original GitHub issueI was wondering if there was a way to add a k8s annotation on a binderhub pod that contains just the repo name? So far I’m able to add the annotation using extraConfig
and KubeSpawner
:
hub:
extraConfig:
myConfig: |
c.KubeSpawner.extra_annotations= {
"repo": '{username}'
}
but this sets the annotation to the escaped pod name with the unique ID on it (I just want the repo name itself), I tried to manipulate the {username}
string (striping the escape characters and unique ID) in the extraConfig
too but it doesn’t seem to work…which I think is because the python code in extraConfig
executes before the pod actually gets spawned?
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
BinderHub Documentation
The primary goal of BinderHub is creating custom computing environments that can be used by many remote users.
Read more >Configuration Reference
K8s annotations for the hub pod. hub.authenticatePrometheus#. JupyterHub native configuration, see the JupyterHub documentation for more information.
Read more >BinderHub on Kubernetes - Jetstream2 Documentation
This should build the container using the Docker-in-Docker pod, push it to the registry on Google Cloud, then spawn a Jupyter Notebook instance...
Read more >jupyterhub/binder
@rochaporto see jupyterhub/binderhub#759 for discussion of resource requests ... e.g. after adding the github url in binder, I can open my jupyter notes...
Read more >CVE-2021-39159 Detail - NVD
BinderHub is a kubernetes-based cloud service that allows users to ... to manipulate images and other user created pods in the deployment, ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
yeah, currently we have ELK set up to send all binderhub notebook std out logs to a single index (and schema)…but I’m trying to explore if we can create a separate index per repo which would allow separate schemas
I didn’t realise we already passed the repo URL over the API. Nice. Then I think the place to make changes is https://github.com/jupyterhub/binderhub/blob/207ae704752cde82f33fc771a3b58aa1ecc04b6d/helm-chart/binderhub/values.yaml#L78 which is the spawner used by BinderHub. Together with maybe hooking into (or adding to) the
_common_annotations
method you linked.Will you use elastic for logging?