"wsl --import" should include regular user setup, and not default to root user.
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 33.7k
- Forks
- 1.8k
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 116
Description
Is your feature request related to a problem? Please describe.
My goal was to take a stock Ubuntu-18.04 WSL instance and clone it with a custom name and logo, for differentiation. When I took an import of the distro from its snapshot, it set up the only the root user. This completely breaks the Remote-WSL workflow from VS Code. Git ops are happening as root, when you want them to happen as the regular user.
You can create a new user from CLI, in your new distro. However, there's no way to tell VS Code at present, when using the "Remote-WSL: New window using distro…" workflow, which user you want it to open with.
Describe the solution you'd like
When you have downloaded a distro from the Microsoft Store, and you open it the first time, you're asked to specify a username and password. This then becomes the default account you log in with.
When you use wsl --import akulbe C:\WSLdistros\akulbe\ ubuntu.tar.gz --version 2, to set up a new distro from a snapshot, it will only have the root user, but it should be asking you to specify a username/password, just like the same process from the Store does.
Describe alternatives you've considered
Only using stock distros.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue identifies the wsl --import command and contrasts it with first-run setup for Store-installed Ubuntu, but it names no implementation files or tests. Start by tracing the import path and existing distribution user-setup flow; done means an imported distro can configure a regular user and use it as the default instead of root.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- linux, ubuntu, vscode
- Domain
- cli, operating-systems
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100