-
Notifications
You must be signed in to change notification settings - Fork 31
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
why you install so many tools via apt? #10
Comments
As I remember it is because nodejs that vscode server is running in container requires them. Nix has linker and libraries installed on unstandard paths and nodejs binary that vscode server uses does not work with these (at least not without hacks). If you find better solution that does not involve hacks, or if you have seen that some of these are not needed anymore, it's more than welcomed. |
I guess you could also use one of the "standard" base images from Microsoft (e.g. |
I am in progress right now to do that. We had previos attempt, so nix installation is broken if install nix via nix into MS container. |
The thing is I am not too much fan of existing Microsoft images, because they have these custom shell scripts to bootstrap environment and plugins. I think we could have nice portable development containers if Microsoft put more effort, but looks like they did minimal to get job done. |
On the second thought, I am not really opposing official Microsoft images that much, so if we can simplify this devcontainer it would be great as well. |
I’m not sure it would simplify it much without sacrificing features, unless (as you say) the base images change a bit. I use the MSFT base images for my experiments because they get me to a nixable container in VSCode relatively quickly, but I don’t need all the extra features here. I was just suggesting it in case the OP wanted to roll their own container. |
ok, seems home-manager approach works. even docker-in-docker works. but only locally. remotely its sucks NixOS/nix#6680 |
this PR based on others works ComposableFi/composable#1530 |
@dzmitry-lahoda If I open this repo https://github.com/xtruder/nix-devcontainer-python-jupyter, that's using nix-devcontainer in github codespaces it works just fine. I don't have any permission issues described here NixOS/nix#6680 |
https://github.com/ComposableFi/composable/blob/dz/byog-container/Dockerfile
|
@dzmitry-lahoda what do you think would be the best way to go forward, making official nix devcontainer image? I have few additional things included in this image like:
What I see is missing is:
You can use flakes with this nix-devcontainer as well. It's not straightforward, as you need to have |
I think best is microsoft/vscode-dev-containers#947 (comment) - use containerTools with home-manager mounted nix with ability to override and add docker-in-docker as feature. so idea that you already in nix shell when is starts. so really I want just
I do not know. Likely it is good. So I will follow other way. I will install and play with nix-env and usual plugins manually. As I like it I will bake them. I am not good in nix and vscode to reload these. So may be home manager can help? So you pick either invest into vscode or into nix. I prefer nix. Because I want to use Helix too and produce artifacts with Hydra. I based my work on https://github.com/jmgilman/dev-container . Also you may read about official stance from MS about features around nix way vs MS way. Definitely I dislike MS way because it is NOT Composable and represents all 👿 why we pick nix first. |
@dsyer What would you like to change about the image?
@offlinehacker Happy to take feedback here. Also see devcontainers/features#67 for a discussion of some refactoring being discussed. Part of the goal here is to allow you to pick and choose a bit better in creating your own bases given you can also use just straight
@dzmitry-lahoda To be clear, Nix is great! But since not everyone uses Nix, we want to be able to support as many scenarios as possible given everyone has their own personal preferences. Features is a way to enable composability across ecosystems, but infofar as the ecosystem you are using already enables it, that's fantastic. There's no requirement on a specific base image for that very reason, and the goal with devcontainers/spec#18 is also to allow dev container metadata to be added regardless of how images are generated. |
yeah, and nix does not support windows. so if assume windows inheritance with features, than nix is no go. |
nix-devcontainer/src/Dockerfile
Line 20 in 1e36169
The text was updated successfully, but these errors were encountered: