Darwin USB network interface configurator for management access to network devices
Project description
Darwin Management NIC Configurator
Configure a USB Ethernet adapter for out-of-band management without letting it take over normal Wi-Fi or tailnet connectivity.
darwin-nic is aimed at bastion and bench workflows where a Mac needs a
temporary management link to network gear while keeping its primary network
path intact.
Status
- macOS is the primary supported platform.
- Linux support is experimental and currently limited.
- Release artifacts are source distributions, wheels, Nix packages, and FlakeHub releases.
- The PyInstaller spec is retained for manual builds, but standalone binaries are not the primary release artifact yet.
Quick Start
# Run the stable v2.1.0 release from FlakeHub
nix run "https://flakehub.com/f/Jesssullivan/DarwinNicUtil/v2.1.0" -- status
# Or run directly from GitHub
nix run github:Jesssullivan/DarwinNicUtil -- status
nix run github:Jesssullivan/DarwinNicUtil -- configure \
--device-ip <device-ipv4> \
--laptop-ip <usb-nic-ipv4> \
--mgmt-network <cidr> \
--preserve-wifi
# Run from a source checkout
uv sync --extra dev
uv run darwin-nic status
uv run darwin-nic configure \
--device-ip <device-ipv4> \
--laptop-ip <usb-nic-ipv4> \
--mgmt-network <cidr> \
--preserve-wifi
For repeated use, create a profile:
darwin-nic init-config
darwin-nic config
darwin-nic configure --profile homelab --preserve-wifi
Install
# Nix profile from FlakeHub
nix profile install "https://flakehub.com/f/Jesssullivan/DarwinNicUtil/v2.1.0"
# Nix profile from GitHub
nix profile install github:Jesssullivan/DarwinNicUtil
# uv from source
uv tool install .
Home Manager and System Manager modules are available under nix/modules/.
For the release shape and productionization summary, see
docs/project-spec.md.
Commands
| Command | Description |
|---|---|
darwin-nic setup |
Interactive guided setup wizard |
darwin-nic configure |
Configure a USB NIC |
darwin-nic status |
Show interfaces, routes, and bastion diagnostics |
darwin-nic dashboard |
Show network monitoring status |
darwin-nic test |
Run basic connectivity checks |
darwin-nic restore |
Restore saved network service order |
darwin-nic config |
Show resolved settings and profiles |
darwin-nic profiles |
List available profiles |
darwin-nic init-config |
Create a starter config file |
Configuration
Settings are loaded in this order, with later sources overriding earlier ones:
| Location | Purpose |
|---|---|
/etc/darwin-nic/config.toml |
System-wide defaults |
~/.config/darwin-nic/config.toml |
User defaults |
~/.darwin-nic.toml |
Legacy user config |
./.darwin-nic.toml |
Directory-local override |
./darwin-nic.toml |
Alternate directory-local override |
DARWIN_NIC_* |
Environment overrides |
Example:
default_profile = "homelab"
[defaults]
preserve_wifi = true
[profiles.homelab]
device_ip = "192.168.88.1"
laptop_ip = "192.168.88.100"
mgmt_network = "192.168.88.0/24"
device_name = "Lab Management Device"
device_type = "network"
See examples/config.toml for a fuller profile example.
Bastion Notes
For a generic tailnet -> bastion host -> USB OOB NIC -> managed network device flow:
- keep
mgmt_networkaligned with the real management subnet; - use
darwin-nic statusbefore making privileged changes; - use
--dry-runto preview interface and route changes; - pre-authenticate with
sudo -vfor non-interactive wrappers; - check
statuswhen raw or link-layer tools work but ordinary sockets fail.
On macOS, status includes scutil --nwi, Tailscale system-extension state,
and recent NECP socket-drop hints when available.
Device-specific hostnames, credentials, OOB MAC addresses, and switch policy belong in downstream operator repositories, not in this generic tool.
Safety
- Protected interfaces such as Wi-Fi, loopback, and system virtual links are not modified.
--preserve-wifikeeps the primary network path ahead of the USB NIC.- Dry-run mode previews intended changes without applying them.
- The emergency restore helper is available at
scripts/emergency-restore.sh.
Requirements
- Python 3.14+ for source and uv installs.
- Nix for flake-based package usage.
- A USB-to-Ethernet adapter.
- macOS for the full current feature set.
Development
just dev
just check
just test
just docs-build
uv build
Run just with no arguments to see all recipes.
Artifacts
Current release artifacts are:
- Python wheel and source distribution from
uv build; - Nix flake package outputs, including FlakeHub
v2.1.0; - MkDocs site artifacts from the docs workflow.
GitHub release, FlakeHub, and docs workflows are present for tag-based publication. The PyPI trusted-publishing workflow is staged but not documented as an install path until the first upload is validated. Standalone binary distribution remains a tracked release follow-up.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file darwin_mgmt_nic_configurator-2.1.1.tar.gz.
File metadata
- Download URL: darwin_mgmt_nic_configurator-2.1.1.tar.gz
- Upload date:
- Size: 134.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dc6af45ec6edaf20ff8146579b2c992babc194e36fb8a39c6f39643d84fd6abb
|
|
| MD5 |
95155e9fb656e84152b19f28ee4f66e8
|
|
| BLAKE2b-256 |
262efc064bd26b136a4b8d61b43b40ddacfc3f744dfa89afc5ec4a74f4d98948
|
Provenance
The following attestation bundles were made for darwin_mgmt_nic_configurator-2.1.1.tar.gz:
Publisher:
release.yml on Jesssullivan/DarwinNicUtil
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
darwin_mgmt_nic_configurator-2.1.1.tar.gz -
Subject digest:
dc6af45ec6edaf20ff8146579b2c992babc194e36fb8a39c6f39643d84fd6abb - Sigstore transparency entry: 1383906626
- Sigstore integration time:
-
Permalink:
Jesssullivan/DarwinNicUtil@6bdbceddbdcb542d21f069e368fd412c593268c5 -
Branch / Tag:
refs/tags/v2.1.1 - Owner: https://github.com/Jesssullivan
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@6bdbceddbdcb542d21f069e368fd412c593268c5 -
Trigger Event:
push
-
Statement type:
File details
Details for the file darwin_mgmt_nic_configurator-2.1.1-py3-none-any.whl.
File metadata
- Download URL: darwin_mgmt_nic_configurator-2.1.1-py3-none-any.whl
- Upload date:
- Size: 63.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9865ce83c81c91df3d0e2be8187a3c28fcd610510c134ff358b4343fec170b0d
|
|
| MD5 |
67eba00c63b121280e0b7b45a46ebd7c
|
|
| BLAKE2b-256 |
b190aba3d98247dc1f4086cc0e09e9017870e8d1c8a30639e79f424e3bd215fe
|
Provenance
The following attestation bundles were made for darwin_mgmt_nic_configurator-2.1.1-py3-none-any.whl:
Publisher:
release.yml on Jesssullivan/DarwinNicUtil
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
darwin_mgmt_nic_configurator-2.1.1-py3-none-any.whl -
Subject digest:
9865ce83c81c91df3d0e2be8187a3c28fcd610510c134ff358b4343fec170b0d - Sigstore transparency entry: 1383906680
- Sigstore integration time:
-
Permalink:
Jesssullivan/DarwinNicUtil@6bdbceddbdcb542d21f069e368fd412c593268c5 -
Branch / Tag:
refs/tags/v2.1.1 - Owner: https://github.com/Jesssullivan
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@6bdbceddbdcb542d21f069e368fd412c593268c5 -
Trigger Event:
push
-
Statement type: