Skip to content

Latest commit

 

History

History
32 lines (21 loc) · 1.15 KB

README.md

File metadata and controls

32 lines (21 loc) · 1.15 KB

blackstrap WSL kernel

GitHub Workflow Status

A Windows Subsystem for Linux kernel originally built for blackstrap VPN.

This kernel can be used wherever WSL needs to support applications that require CONNMARK, like Wireguard in Docker (https://docs.linuxserver.io/images/docker-wireguard).

The Dockerfile pulls and builds the latest released version of the WSL Linux kernel from https://github.com/microsoft/WSL2-Linux-Kernel. Building the kernel takes 10-15 minutes.

The built kernel is saved to /wsl-kernel within the image and can be copied out for use:

# build
docker build . -t blackstrap-wsl-kernel

# extract kernel image
docker create --name blackstrap-wsl-kernel
docker cp blackstrap-wsl-kernel:/wsl-kernel PATH_TO_SAVE
docker rm blackstrap-wsl-kernel

To use it, specify the custom kernel in your ~/.wslconfig file and restart WSL with wsl --shutdown. Also ensure to escape the path (\ should be \\) you set.

[wsl2]
kernel=PATH_TO_KERNEL

License

Put a license here.