microsoft / WSL-DistroLauncher

Sample/reference launcher app for WSL distro Microsoft Store packages.
MIT License
1.69k stars 521 forks source link

Use the windows user CN as WSL2 distro username #87

Open matt6697 opened 3 years ago

matt6697 commented 3 years ago

Would it be possible to add a launcher option to automatically retrieve and configure the Active Directory CN of the logged-in user as default WSL2 user ? This would help to ensure smooth WSL2 deployment in enterprise environment without prompting users at WSL2 initial launch.

https://docs.microsoft.com/fr-fr/windows/win32/api/winbase/nf-winbase-getusernamea?redirectedfrom=MSDN

A-23187 commented 3 years ago

This repo is just a reference implementation of the WSL distro launcher. I think you can check if the distro you want to deploy supports some additional options for automatic deployment.