-
-
Notifications
You must be signed in to change notification settings - Fork 120
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
Package for Windows Store #63
Comments
I started looking through this tonight. I'd be interested to hear ideas around how we could take advantage of having an executable in the default Windows There's a nice little API within there where you can run arbitrary commands within WSL through |
I have implemented a custom distro launcher (#94). A test-signed build can be found here. To install it, run the included If you discover any issues, please leave a comment on the Pull Request |
@nzbr The link to your test-signed build does not work. |
The build artifact I linked has probably expired since then. You should alwasys be able to grab the |
This issue has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/nix-installer-workgroup/21495/17 |
Has there been any progress? |
Not to much on #94 |
Hi, is there any progress towards having a NixOS in the Microsoft Store to use in WSL2? |
The distrolauncher is already done, but I'm not sure how we can put it in the store and since @nzbr is the maintainer, maybe should be he doing it? |
The latest CI runs already build the store package. It'd be great if some of you would test the thing to see if it works on other computers than mine. Just grab the |
Hi @nzbr, thanks for your work! After running the Install.ps1 succeeded, the NixOS item showed in the start menu, but it quite imediately after click. Run
Running it with administrator got the same error. I'm using Win10 22H2 with Windows Feature Experience Pack 1000.19052.1000.0. |
Can you try again with |
@nzbr I've got the same error:
|
@nzbr Sorry my bad. I resolved the problem, just running I guess my current machine don't activate WSL2 before, so there are some components are missing.
|
There should probably be a check if WSL is actually installed. Gonna make an issue for it Edit: #421 |
I also tried it. Is there a reason that the shell initially starts up with the working directory of |
@JojOatXGME the shell working directory is the same the launcher gets started with. The others probbably have some sort of check so that it gets set to the home directory in that case |
Upstream issue microsoft/WSL#11206 |
@onny I think someone from the NixOS side needs to publish the launcher to the Microsoft Store. See the instructions here |
Hi there! I'm the creator of Pengwin, Fedora Remix for WSL, and Pengwin Enterprise, all Linux distros published in the Store, I also managed Ubuntu's publication in the Store during my time at Canonical. I would be happy to help get NixOS published in the Store. I am not familiar with building NixOS images, but if I can partner with someone who is, I can then advise on how to automate the build pipeline and publish them regularly to the Store. |
I think there's a little more work to be done before it can be listed. I'm trying to set up a Nix instance on W10 22H. I've started with the From what I can tell there's no hardware-configuration.nix included initially. The docs mention needing to add channels, as my The other item has been previously mentioned. (#63 (comment)) The working directory set when the image starts is -I'm assuming, haven't thoroughly tested- a passthrough to the Windows host system disks? Which is sorta cool and nice and useful in one way, but if we want to do what user in the comment mentioned and set a home directory, we will need some fileSystems definition as when I try to load a configuration.nix that will start to include system packages, rebuild fails needing it.
hardware-configuration.nix is usually left up to the user for their system right? Is there any sort of minimal virtual mount/directory creation step we can do as a part of set up that could give us a minimal Finally, I enabled developer mode and loaded the testing cert to test a build artifact built last week, https://github.com/nix-community/NixOS-WSL/actions/runs/9638299838. Execution went smoothly and no errors hung around, but I did this after having installed a distro labeled |
@TLMcNulty |
Going on my limited understanding of
I defer to your knowledge on needing a filesystem definition for a user home directory. Usually the WSL-Distrolauncher package for new user setup handles adding a default user and by extension creating a home directory. That home directory is then set as the default in WSL and stored in the Windows Registry. Local drives are automatically mounted at
This is interesting. This could be configured in the distro by adding logic to the WSL-Distrolauncher C++ distro initiation code where the default new user is created. GRUB is not needed though, it can be installed (several WSL distros still ship with GRUB in them), but it will be bypassed by the WSL's own boot/init flow.
See above. I also would need to hear from someone with more Nix experience to property advise on this.
It's possible it overwrote the existing NixOS. In the future, I would recommend removing the .tar.gz import, restarting WSL, and then trying this from scratch. Hope some of this helps. |
Is there a way to define filesystem mounts and user creation only in the NixOS configuration, so that everything is in one place? Or do those events occur before the distribution is started? |
WSL automatically mounts the root file system and This would all occur before The options here are limited and geared towards more traditional Linux distros. It's possible to disable automount of |
The |
The Launcher uses There is no first-time setup wizard like on the other distros, because it would require editing the configuration.nix. The process for changing the user name is documented now though: https://nix-community.github.io/NixOS-WSL/how-to/change-username.html |
It would be nice to just have this available on the Windows Store. It's more or less just a matter of making a manifest and emailing the right people.
See: github.com/microsoft/WSL-DistroLauncher
The text was updated successfully, but these errors were encountered: