> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kombify.io/llms.txt
> Use this file to discover all available pages before exploring further.

# stackkit vpn

> The optional VPN add-on: switch it on with WireGuard, Headscale, Tailscale or Pangolin, list its peers, switch it off

The optional VPN add-on: switch it on with WireGuard, Headscale, Tailscale or Pangolin, list its peers, switch it off.

The VPN add-on is never a default in any mode or kit: the Owner switches it on at the Authority, in addition to the standard reach paths, with one of four tools. Every enrolled, unrevoked device then receives its peer from the peer service on the node site address (port 9444) with its device credential, in the same enrollment; revoking the device or removing its person removes the peer, and the reconciler applies it to the live interface or the tool's coordination server within seconds. A peer reaches only the node site address, and every request through it still carries the sign-in and device proof its route asks for.

```bash theme={null}
stackkit vpn [flags]
```

Subcommands: [`stackkit vpn disable`](#stackkit-vpn-disable), [`stackkit vpn enable`](#stackkit-vpn-enable), [`stackkit vpn reconcile`](#stackkit-vpn-reconcile), [`stackkit vpn status`](#stackkit-vpn-status)

## stackkit vpn disable

Switch the VPN add-on off: remove every peer, the tool's runtime and the peer service (requires root).

```bash theme={null}
stackkit vpn disable [flags]
```

## stackkit vpn enable

Switch the VPN add-on on with one tool (requires root at the Authority).

Records the Owner's opt-in, starts the tool (WireGuard on the host's wireguard-tools; Headscale, the Tailscale node and Newt as their pinned upstream images), registers the Authority as the tool's node that routes only its site address, and starts stackkit-vpn.service: the peer service on port 9444 and the reconciler. Tool secrets are read from files into the add-on's custody and never printed.

```text theme={null}
  wireguard  --endpoint host:port (UDP, forwarded to 51820; the peer service is host:9444)
  headscale  --endpoint host:port (TCP, forwarded to 9444: the peer service carries the control endpoint; UDP 3478 for STUN)
  tailscale  --tailnet <name> --oauth-client-file <json with clientId, clientSecret>
  pangolin   --pangolin-endpoint https://… --pangolin-api https://…/v1 --pangolin-org <id> --pangolin-site <n> --newt-id <id> --newt-secret-file f --api-key-file f [--ca-file pem]
```

```bash theme={null}
stackkit vpn enable [flags]
```

| Flag | Type | Default | Description |
| - | - | - | - |
| `--api-key-file` | string | — | file with an organization API key that manages clients and site resources (pangolin) |
| `--ca-file` | string | — | PEM of the CA of a self-hosted Pangolin server with a private certificate (pangolin) |
| `--endpoint` | string | — | public host:port devices dial from away (wireguard, headscale) |
| `--newt-id` | string | — | the site's Newt ID (pangolin) |
| `--newt-secret-file` | string | — | file with the site's Newt secret (pangolin) |
| `--oauth-client-file` | string | — | JSON file with the tailnet OAuth client's clientId and clientSecret (tailscale) |
| `--pangolin-api` | string | — | https URL of the Pangolin Integration API, ending in /v1 (pangolin) |
| `--pangolin-endpoint` | string | — | https origin of the Owner's Pangolin server (pangolin) |
| `--pangolin-org` | string | — | Pangolin organization ID (pangolin) |
| `--pangolin-site` | int | — | numeric ID of this Authority's Newt site (pangolin) |
| `--tailnet` | string | — | the Owner's tailnet name (tailscale) |
| `--tool` | string | — | **Required.** wireguard, headscale, tailscale or pangolin (no default) |

## stackkit vpn reconcile

Apply the device registry to the tool once: drop the peers of revoked, expired and removed devices (requires root).

```bash theme={null}
stackkit vpn reconcile [flags]
```

## stackkit vpn status

Show the selected tool, the peer ledger and the tool's live device nodes.

```bash theme={null}
stackkit vpn status [flags]
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.