Skip to main content

A CLI tool to expose WSL ports to the LAN

Project description

wsl-expose

A convenient CLI tool to expose Windows Subsystem for Linux (WSL) ports to the Local Area Network (LAN) by automatically configuring Windows netsh portproxy and Firewall rules.

Installation

Ensure you are in the project root directory where pyproject.toml is located, then run:

uv tool install .

Usage

Note: You must run this command from an Administrator terminal (e.g., PowerShell as Administrator) to add or remove ports, because Windows netsh and firewall configurations require elevated privileges.

Expose a Port

To expose a port (e.g., 8080) running inside your WSL instance to your Windows host's LAN IP:

wsl-expose add 8080

Remove an Exposed Port

To remove the port mapping and firewall rule:

wsl-expose remove 8080

List Exposed Ports

To see all currently configured WSL port proxies:

wsl-expose list

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wsl_expose-0.1.2.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

wsl_expose-0.1.2-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file wsl_expose-0.1.2.tar.gz.

File metadata

  • Download URL: wsl_expose-0.1.2.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.14

File hashes

Hashes for wsl_expose-0.1.2.tar.gz
Algorithm Hash digest
SHA256 954a0233dc593811ff4b57b81d69695e189411cf638f7632fd62d43b42b2cf57
MD5 5fd41e61439b87a3a6f1c1313280c718
BLAKE2b-256 437302314a69851a13e5f0f3de4c5dc8cafe315892105bc9972dd3b519821367

See more details on using hashes here.

File details

Details for the file wsl_expose-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: wsl_expose-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.14

File hashes

Hashes for wsl_expose-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 c8ade610e214e8e770a964a393c3bc124454f68d384154911b58a8b404d08465
MD5 2069b5bfe904ddcfcf1f0ee2a2b4d0ae
BLAKE2b-256 25a2097e6ce351e2a30a5d68069540456a992cfb9971b4a50658e6728a690364

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page