Add documentation for setting environment variables (e.g. for installing extra packages)
See original GitHub issueI could be wrong, but this seems like a fairly important detail in some deployments. Creating custom OS images with Packer is obviously better but that’s a fairly high bar for a lot of users, probably. I found that this is currently supported with the following caveats:
- It cannot be configured in
cloudprovider.yaml
or environment variables on the client (i.e.DASK_CLOUDPROVIDER__GCP__ENV_VARS
would be ignored) - If passed directly in code, it must be quoted. For example,
GCPCluster(..., env_vars=dict(EXTRA_CONDA_PACKAGES="numba xarray"))
will not work because the render code (here) does not quote values and since the docker run statement built is already being yaml-escaped via single quotes, the values must be double quoted. The variables must be passed like this:EXTRA_CONDA_PACKAGES="\"numba xarray\""
, notEXTRA_CONDA_PACKAGES="'numba xarray'"
.
Documentation for new users on this would be very helpful. Allowing the env_vars
to come from cloudprovider.yaml
would also be nice.
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
Advanced Topics in Packaging — Spack Tutorial documentation
Set environment variables in dependent packages at build-time¶. Dependencies can set environment variables that are required when their dependents build. For ...
Read more >Environment variables in Compose | Docker Documentation
You can set default values for environment variables using a .env file, which Compose automatically looks for in project directory (parent folder of...
Read more >Custom options and environment — Dataiku DSS 11 ...
The options for pip, virtualenv, R and conda can be found in the relevant documentation. ... You can apply regular pip, virtualenv or...
Read more >Introduction to environment variables - CircleCI
Use environment variables to set up various configuration options, and keep your ... delete the current variable, and add it again with the...
Read more >Use environment variables in solutions - Power Apps
Select Settings > General and enable the setting to Automatically create environment variables when adding data sources. Add a New data ...
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
A little, it seems nice. I think the performance increases here will help things, but my worry is about reproducibility. The times I’ve tried to dump out a conda environment and recreate it recently have failed because packages go missing from anaconda.org. Especially when developing on nighly builds.
Thing conversation reminds me of this meme.
Nicely put. Smaller would be great but maybe the need for tools with layered complexity (e.g. numpy -> dask -> xarray) is inevitable to meet the maximum sophistication of a larger number of users. I always imagine that scientists collect at the ends of those spectrums though – I wonder how true that is.
Oh interesting, had not seen that before. I like the caching metaphor. It still surprises me a bit that installation of compiled packages via conda can’t be made to be faster than the download and execution of an entire containerized OS image that contains all those same packages. Have you used mamba much yet? I have not at all, but I’m curious if you see that as likely to close the gap.