feat(wsl): detect mirrored vs NAT mode for winhost routing #23

Merged
guochao merged 1 commit from guochao/nixos-config:master into master 2026-05-01 14:47:08 +00:00
Owner

Replace inline activation script with external setup-winhost.sh.
Detect WSL network mode via:

  1. .wslconfig networkingMode setting (most authoritative)
  2. eth0 subnet (172.x.x.x indicates NAT)
  3. IP overlap between WSL and Windows (mirrored)

Use 127.0.0.1 for mirrored, default gateway for NAT,
fallback to 127.0.0.1 when gateway is unavailable.

Co-Authored-By: Claude Opus 4.7 noreply@anthropic.com

Replace inline activation script with external setup-winhost.sh. Detect WSL network mode via: 1. .wslconfig networkingMode setting (most authoritative) 2. eth0 subnet (172.x.x.x indicates NAT) 3. IP overlap between WSL and Windows (mirrored) Use 127.0.0.1 for mirrored, default gateway for NAT, fallback to 127.0.0.1 when gateway is unavailable. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
feat(wsl): detect mirrored vs NAT mode for winhost routing
Some checks failed
Nix Flake Update / nix-flake-update (push) Has been cancelled
c011062423
Replace inline activation script with external setup-winhost.sh.
Detect WSL network mode via:
  1. .wslconfig networkingMode setting (most authoritative)
  2. eth0 subnet (172.x.x.x indicates NAT)
  3. IP overlap between WSL and Windows (mirrored)

Use 127.0.0.1 for mirrored, default gateway for NAT,
fallback to 127.0.0.1 when gateway is unavailable.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
guochao merged commit c011062423 into master 2026-05-01 14:47:08 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: public/nixos-config#23
No description provided.