Skip to content
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

Setting Spawner.environment does not seem to affect KubeSpawner.get_env() #485

Open
danielballan opened this issue Feb 24, 2021 · 1 comment
Labels

Comments

@danielballan
Copy link

danielballan commented Feb 24, 2021

Running Helm Chart version 0.11.1 (JupyterHub 1.3.0, KubeSpawner 0.15.0), I find that setting:

hub:
  extraConfig:
    00-spawner-env-config: |
      c.KubeSpawner.environment.update({"TEST_ENV": "HELLO"})

works as expected, setting TEST_ENV in the user environment, but

hub:
  extraConfig:
    00-spawner-env-config: |
      c.Spawner.environment.update({"TEST_ENV": "HELLO"})

has no effect on the user environment.

I'm sure this kind of configuration merging has worked for me in other contexts, and the traitlets Configurable docs are really clear on this exact point.

I have checked this a couple times to check that I'm not getting confused about what I'm seeing. It is definitely the case that setting the config Spawner instead of KubeSpawner does not set the environment variable. For my immediate purposes, this is a sufficient workaround, but it would be good to understand what is happening.

Originally reported in jupyterhub/zero-to-jupyterhub-k8s#2062 as Point (3). Sent here by @consideRatio.

@welcome
Copy link

welcome bot commented Feb 24, 2021

Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! 🤗

If you haven't done so already, check out Jupyter's Code of Conduct. Also, please try to follow the issue template as it helps other other community members to contribute more effectively.
welcome
You can meet the other Jovyans by joining our Discourse forum. There is also an intro thread there where you can stop by and say Hi! 👋

Welcome to the Jupyter community! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants