Skip to content

Instantly share code, notes, and snippets.

@Staggerlee011
Created December 14, 2020 15:04
Show Gist options
  • Save Staggerlee011/ed65f10938f944895ed80a373c5f4ef6 to your computer and use it in GitHub Desktop.
Save Staggerlee011/ed65f10938f944895ed80a373c5f4ef6 to your computer and use it in GitHub Desktop.
wsl2-setup-config
## Enable hyper-v and wsl
Enable-WindowsOptionalFeature -Online -FeatureName VirtualMachinePlatform -NoRestart
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux -NoRestart
## Download distro of choice (https://docs.microsoft.com/en-us/windows/wsl/install-manual)
Invoke-WebRequest https://aka.ms/wsl-ubuntu-1804 -OutFile ubuntu-18-04.appx -UseBasicParsing
Add-AppxPackage .\ubuntu-18-04.appx
## Second example (kali)
Invoke-WebRequest https://aka.ms/wsl-kali-linux-new -OutFile kali.appx -UseBasicParsing
Add-AppxPackage .\kali.appx
kali.exe
## Check wsl distro list
wsl -l -v
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment