Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Sep 20 14:20
    jakepaw opened #2738
  • Sep 20 10:49
    giansoldati commented #2720
  • Sep 20 00:12
    eslavich commented #2733
  • Sep 19 21:17
    Zsailer commented #2698
  • Sep 19 18:23
    Zsailer synchronize #2698
  • Sep 19 17:47
    minrk commented #2698
  • Sep 19 16:31
    vhaldemar commented #2732
  • Sep 19 16:17
    Zsailer commented #2698
  • Sep 19 15:49
    yuvipanda commented #2698
  • Sep 19 15:41
    Zsailer commented #2698
  • Sep 19 15:38
    yuvipanda commented #2721
  • Sep 19 15:32
    yuvipanda commented #2698
  • Sep 19 15:27
    shitala-cuelogic opened #2737
  • Sep 19 14:49
    willingc closed #2718
  • Sep 19 14:49
    willingc commented #2718
  • Sep 19 14:46
    willingc labeled #2719
  • Sep 19 14:46
    willingc commented #2719
  • Sep 19 14:45
    willingc labeled #2719
  • Sep 19 14:44
    willingc closed #2720
  • Sep 19 14:44
    willingc commented #2720
Yuvi Panda
@yuvipanda
:D
@betatim @consideRatio I'm going to try deploying https://github.com/uswitch/nidhogg :)
Tim Head
@betatim
and a big :+1: to discussions. i told my team at work that time spent discussing, scoping, rescoping, rethinking isn't wasted. based on spending most of an afternoon chatting with @consideRatio about sticky build pods and the fact that we arrived at a solution that is super short and nice
Yuvi Panda
@yuvipanda
w00t
Tim Head
@betatim
and that we started out thinking we'd need to write a custom scheduler (like custom custom, not just tweaking the weights inn the k8s scheduler)
Yuvi Panda
@yuvipanda
deploying that is weird and I don't understand go :|
it's also more complicated because I've like 6 hubs on the same cluster, so I don't wanna block a hub with smaller image size from scheduling on a new node simply because a bigger image isn't there yet. I'll have to specify taints for each hub then that tolerates every other hub's image missing
Ray Zhang
@OneRaynyDay
Hey guys! I have a quick question - I know after authentication and spawning the user requests gets proxied through configurable-http-proxy (or whichever proxy we replace that with). If I have a hub process that may have more endpoints exposed regarding metrics, would that congest traffic for users?
Yuvi Panda
@yuvipanda
we've about 5k users without any proxy bottlenecking
so you're probably fine
Erik Sundell
@consideRatio
@betatim :heart: I really appreciated the last day when we had time to discuss that at length! It is a memory i treasure, it was really rewarding in many ways
@yuvipanda oh, yeah me too I found it to be hard to understand, I wrote a response in jupyterhub/zero-to-jupyterhub-k8s#1414 about these parts
Ray Zhang
@OneRaynyDay

Nice! Great to know the scaling capabilities @yuvipanda . Do you have endpoints exposed for metrics on the hub process? I see CHP is a separate process through ps auxf

root      ... Ssl  Aug31  82:03 node /usr/bin/configurable-http-proxy --ip  --port 8000 --api-ip 127.0.0.1 --api-port 8001 --default-target http://127.0.0.1:8081 --

So I'm guessing traffic won't be affected by the endpoints? Just wanted to make sure though

Yuvi Panda
@yuvipanda
we run on kubernetes, and we run them as separate containers. we do collect metrics out of there, and don't really have any issues
Ray Zhang
@OneRaynyDay
Awesome, thank you. I'm also curious on one thing since you're using kube - from what I can understand hub is a stateful process which means it's hard to make it HA. How do you get around these issues? (i.e. when a user is in the spawning state, and the hub pod goes down, spinning hub back up will drop the spawning state of the user)
Yuvi Panda
@yuvipanda
we don't. it's practically not been a problem, but yeah it's an issue
Ray Zhang
@OneRaynyDay
hmm... Interesting. And you have a single proxy process right? Otherwise you'll need consistency b/w proxies for user sessions
Yuvi Panda
@yuvipanda
yep. the traefik proxy work that's ongoing should fix that
our proxy process runs in a separate container so restarting hub doesn't restart proxy
Erik Sundell
@consideRatio
@OneRaynyDay, there should be only one proxy process, but if it isnt it can cause malfunctions. Only the very latest dev releases have ensured this is the case though! See: jupyterhub/zero-to-jupyterhub-k8s#1401
(oh, assuming kubernetes deployment atm)
Ray Zhang
@OneRaynyDay
Ah, gotcha. Thanks will take a look :) These are all things that prevented our team from moving from IAC to containerized deployment of jupyterhub.
Well, not "prevented", just dissuaded.
Ray Zhang
@OneRaynyDay
Hi, question: In the tests portion of jupyterhub/jupyterhub, I see in test_orm.py that db is a variable that is used globally but not defined anywhere. How are these tests run usually?
Jakub Konieczny
@kubadotka
Hello!
I want to install jupyterlab on system actually running jupyterhub.
Is there a official documentation about steps to be taken and versions of conda packages ?
Min RK
@minrk
@kubadotka you can use jupyterlab with jupyterhub. You would only change the command to launch c.Spawner.command = 'jupyter-labhub' which will launch jupyterlab for your users.
@OneRaynyDay that's a pytests fixture, defined in conftest
Olivier Bornet
@PuckCh

Hi all.

I'm setting JupyterHub on Kubernetes, using KubeSpawner. All is fine with standard images, but I want to customize more to fit our needs (and maybe use nbgrader).

I want to set homeMountPath with different value depending on the image selected by the user.
I have a config file like:

...
hub:
    extraConfig:
        spawner: |
            profiles = [
                {
                    'display_name': "Image 1",
                    'description': "Standard image, with Python kernel.",
                    'kubespawner_override': {
                        'image': 'my-custom-image-1',
                    },
                {
                    'display_name': "Image 2",
                    'description': "Another image, with Python and R kernel.",
                    'kubespawner_override': {
                        'image': 'my-custom-image-2',
                    },
                },
            def populate_options(self):
                self.profile_list = profiles
                return self._options_form_default()
            c.KubeSpawner.options_form = populate_options
...
singleuser:
    storage:
        homeMountPath: /home/someuser
...

for the default mount point. For some image, like for example with Image 2,
I want to use /home/anotheruser instead. I have try with this code for the Image 2 part:

{
    'display_name': "Image 2",
    'default': True,
    'description': "Another image, with Python and R kernel.",
    'kubespawner_override': {
        'image': 'my-custom-image-2',
        'storage': {
            'home_mount_path': '/home/anotheruser',
        },
    },
},

without success. The user home is always mounted on '/home/someuser'. I also have try with 'homeMountPath' instead of 'home_mount_path', and it's the same, it's

What is the correct way to configure it? Is it possible?

Chico Venancio
@chicocvenancio
Chico Venancio
@chicocvenancio
perhaps if you're using the same volume as the standard profile, just on a different path;
{
    'display_name': "Image 2",
    'default': True,
    'description': "Another image, with Python and R kernel.",
    'kubespawner_override': {
        'image': 'my-custom-image-2',
        'volume_mounts': {
            'name': 'volume-{username}'
            'mount_path': '/home/anotheruser',
        },
    },
},
Olivier Bornet
@PuckCh

@chicocvenancio: thanks for the tip. I have try with something like:

...
                 {
                    'display_name': "Image 2",
                    'description': "Another image, with Python and R kernel.",
                    'kubespawner_override': {
                        'image': 'my-custom-image-2',
                        'volume_mounts': c.KubeSpawner.volume_mounts + [{
                            'name': 'volume-{username}',
                            'mount_path': '/home/anotheruser',
                        }],
                    },
                },
...

and now, I have the two monts /home/someuser and /home/anotheruser. I will make a replace of /home/someuser with /home/anotheruser instead, and it should do what I want. Thanks.

PS. at the same time, I have an answer for another question I'm trying to solve: how to add different mounts for different images. I was trying with extraVolumes and extraVolumeMounts, but doing it directly on volume_mounts and mounts seems to be the right way to go. Thanks a lots.

Chico Venancio
@chicocvenancio
extraVolumes and extraVolumeMounts are for values.yaml, volume_mounts and mounts for python and kubespawner_override
(iirc)
Maria Isabel Restrepo
@mirestrepo
Hi Everyone - A question that may be easy. We have our students configure ssh keys to connect to their GitHub. When the server gets restarted, the permissions of the .ssh folder get changed to 660 which is too open for the Ursa_key. What is the recommended way to have user-permissions be "persistent"? Thank you!
Chico Venancio
@chicocvenancio
@mirestrepo the keys persist but change permission?
Maria Isabel Restrepo
@mirestrepo
yes, correct
on creation they are 600, when server shutdowns and restarts they are 660
and for reference we are using GKE with default PV for users.
Chico Venancio
@chicocvenancio
huh, I can reproduce that
Chico Venancio
@chicocvenancio
@mirestrepo Was not aware of this. Seems like a bug to me. What version of the singleuser image are you using?
Erik Sundell
@consideRatio
Are they created in a lifecycle hook? i also run chmod when i create a ssh key from within a lifecycle hook
Chico Venancio
@chicocvenancio
@consideRatio I reproduced it without a lifecycle hook, just creating the folder .ssh is enough to see the behavior
Chico Venancio
@chicocvenancio
@mirestrepo using a lifecycle hook to chmod it back is probably your best option.
I think this is related to docker/k8s volume mounting, but I'm not sure.
eylenth
@eylenth
Hi, can someone pick up my issue that I have created in the issues section? jupyterhub/jupyterhub#2666 Any help would be appreciated.
Maria Isabel Restrepo
@mirestrepo
@chicocvenancio Thank you. Agree the lifecycle hooks is the way to go for won. I would love to understand more about docker/k8s volume mounting to know is this is a behavior I should keep in mind, or if it's a "bug"
Edmund Miller
@Emiller88

Hey all, I'm having an issue using IRkernel with JupyterHub

if (!requireNamespace("BiocManager", quietly = TRUE))
    install.packages("BiocManager")

BiocManager::install("DESeq2")

Returns

Bioconductor version 3.9 (BiocManager 1.30.4), R 3.6.1 (2019-07-05)
Installing package(s) 'BiocVersion', 'DESeq2'
Warning message in install.packages(pkgs = doing, lib = lib, repos = repos, ...):
“'lib = "/opt/tljh/user/lib/R/library"' is not writable”

Error in install.packages(pkgs = doing, lib = lib, repos = repos, ...): unable to install packages
Traceback:

1. BiocManager::install("DESeq2")
2. .install(pkgs, repos = repos, ...)
3. .install_repos(pkgs, lib = lib, repos = repos, ...)
4. install.packages(pkgs = doing, lib = lib, repos = repos, ...)
5. stop("unable to install packages")
I've tried installing through my conda env but that didn't work either
NawabiCoder
@nawabiCoder_twitter
@chicocvenancio
I hope you are doing good.
I am new to jupyterhub/jupyter notebook
Can you please suggest a best way to mount configmap to user-pods from hub singleuser configuration?
NawabiCoder
@nawabiCoder_twitter
@here can you please share me a document where all the configuration is available with detailed references and examples?