# VPN Gateway

VPN Gateway is a self-hosted network services app. A self-hosted VPN gateway for homelab container traffic, built on hotio's Alpine VPN base, that adds nftables bandwidth limiting, scheduling, hot-reload, and a web UI. It is open source and self-hosted, installable on Unraid.

Canonical page: https://ourlocalhost.com/app/3460/vpn-gateway

## Description

A self-hosted VPN gateway for homelab container traffic, built on hotio's Alpine VPN base, that adds nftables bandwidth limiting, scheduling, hot-reload, and a web UI.

## Platform availability

Available on 1 of 10 platforms: Unraid.

## Health score

49/100 (Fair), based on 4 of 4 factors.
- Maintained: 82 (last commit 13 days ago)
- Popular: 19 (8 GitHub stars)
- Easy to install: 35 (1 install platform, install notes, Docker image)
- Light to run: 30 (2.2998 GB minimum RAM)

## Links

- GitHub: https://github.com/prophetse7en/vpn-gateway
- Unraid: https://ca.unraid.net/apps/vpn-gateway-1l3kyaq1jsouj2?q=vpn-gateway

## Common questions

### How do I route my existing containers through the VPN?

Use vpn-gateway as a drop-in replacement for the hotio Alpine VPN base image. Attach other containers to its network namespace, for example by running them with --net=container:vpn-gateway.

### Do I need to restart the container after changing bandwidth rules?

No. You can edit traffic.conf and the changes hot-reload within about 10 seconds without restarting the container.

### Which port should I expose for the web UI?

Expose port 6050, open it in a browser, and use the /setup page to create an admin account. The API key can then be used for Homepage or scripts.

### Should I pull the latest tag automatically?

No, use a pinned version tag rather than latest. A breaking update can leave containers routed through vpn-gateway disconnected until you fix or roll it back.

### Does vpn-gateway recover if the underlying VPN connection reconnects?

Yes, a watchdog detects when hotio rebuilds its nftables table and re-applies the rate-limit rules.

### Do traffic statistics survive container restarts?

Yes, traffic data survives container restarts. It is saved every 5 minutes and again on shutdown.

---
Source: Our Local Host (https://ourlocalhost.com/app/3460/vpn-gateway), the self-hosted and open-source app directory.
