-
Notifications
You must be signed in to change notification settings - Fork 830
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
Unattended install of WSL #3369
Comments
The 4th step of installation on page that I linked is Create a UNIX user - this is a prompt that I can't skip, I would like to be able to provide this user (eventually keep default). |
|
@Owdaan That user creating command |
@voskrese I don't see how this may help. Regarding edit - of course I can set that, but first I need to have WSL installed (and installer always prompts for username) |
You want microsoft/windows-dev-box-setup-scripts#32 and probably microsoft/windows-dev-box-setup-scripts#33 as well. Feel free to pitch in to help with those initiatives. |
Distributions that are up-to-date with the distribution launcher sample have an option for non-interactive install. I know the Ubuntu 18.04 app supports this: |
@benhillis This looks exactly what I need - is there an public link to new version of Ubuntu (1804) like it was for 1604? I can't find any and I'm not sure if i will get access to businessstore... |
@Owdaan They released this blog post yesterday to help address your question (other than business store) https://blogs.msdn.microsoft.com/commandline/2018/07/09/upgrading-ubuntu/ |
Isn't good enough for my use case. I want an unattended install that is the same as installing from the store, but where I supply a default account and password. I'm trying to set up a dev environment, and I don't want my devs to have to worry about running Even the internal Microsoft boxstarter team punts on this: https://github.com/microsoft/windows-dev-box-setup-scripts/blob/d488050/README.md#how-to-run-the-scripts
without really explaining how to "use this user going forward". Using @MVoz's very helpful deep knowledge, I was able to make an almost-scripted install by:
It's not totally scripted, because the "get the GUID" step is hard. I'm not familiar enough (yet!) with Powershell to work out how to parse that out (oh, I guess there's a whole powershell regedit API isn't there?). Um, anyway I guess I've answered my own question: you can do an unattended install if you just need linux with a root user, but you can't really do it if you want a regular user account, at least not yet. kicking it upstream: microsoft/WSL-DistroLauncher#90 |
I got an unattended install with a non-root user account fully working thanks to powershell:
|
Ahh I didn't read the docs enough, there's
|
Or, this is probably even better:
This makes doing initial system updates trickier though, because DistroLauncher doesn't come with
or:
|
Your Windows build number: Microsoft Windows [Version 10.0.17134.112]
What you're doing and what's happening: No way to do unattended install of WSL
What's wrong / what should be happening instead:
I have to install WSL on several machine and I would like to do it in automated manner (as a part of a workstation setup, so it should work without any prompts etc). I've tried with this approach: https://docs.microsoft.com/en-us/windows/wsl/install-on-server but it still requires input... Is there a way to setup WSL without user action?
The text was updated successfully, but these errors were encountered: