Tailscale creates a secure mesh VPN between your devices using WireGuard. It’s ideal for accessing HAPI from your personal devices or sharing with a team without exposing services to the public internet.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/tiann/hapi/llms.txt
Use this file to discover all available pages before exploring further.
Why Tailscale?
Private network
Zero-trust network access without public exposure
Simple setup
Install, authenticate, and you’re connected
Multi-device
Access from all your devices automatically
Team sharing
Share access with team members securely
Prerequisites
- Tailscale account (free for personal use, up to 100 devices)
- Tailscale installed on all devices that need access
Setup
Install Tailscale
Download from tailscale.com/download
Configuration
HAPI environment variables
Use MagicDNS (recommended)
Tailscale provides MagicDNS for friendly hostnames:- Enable MagicDNS in Tailscale admin console
- Your machine gets a hostname like
machine-name.tail-xxxxx.ts.net - Use the hostname instead of IP:
MagicDNS makes URLs stable across IP changes and easier to remember.
HTTPS with Tailscale
Option 1: Tailscale HTTPS (recommended)
Tailscale can provision HTTPS certificates automatically:Option 2: Tailscale Serve (beta)
Tailscale’s built-in reverse proxy (no separate web server needed):Tailscale Serve is in beta. See Tailscale Serve docs for details.
Team access
Share HAPI with team members:Invite team members
In Tailscale admin console, invite users to your tailnet.
Optional: Set up ACLs
Control who can access HAPI using Tailscale ACLs:
CLI configuration
On client machines (also on Tailscale), configure the CLI:Run as background service
Start both Tailscale and HAPI on boot
Linux (systemd):Telegram integration
Tailscale with HTTPS enables Telegram Mini App:Troubleshooting
Cannot access from other devices
-
Verify Tailscale is running:
-
Check HAPI is listening on
0.0.0.0: -
Test locally first:
-
Verify firewall isn’t blocking:
MagicDNS not working
- Enable MagicDNS in admin console
- Restart Tailscale:
- Verify DNS:
HTTPS certificate errors
-
Regenerate certificates:
-
Verify certificate files exist:
- Check reverse proxy configuration
Comparison with other options
| Feature | Relay | Tailscale | Self-hosted |
|---|---|---|---|
| Setup complexity | One command | Install + auth | Port forwarding + HTTPS |
| Public access | Yes | No (private network) | Yes |
| Network type | Public relay | Private VPN | Public or private |
| Team sharing | Via URL | Via tailnet | Via firewall rules |
| Encryption | WireGuard + TLS | WireGuard | TLS (if configured) |
| Cost | Free | Free (up to 100 devices) | Server costs |
When to use Tailscale
Ideal when you:- Want secure access across your devices
- Need to share with a small team privately
- Don’t want public internet exposure
- Already use Tailscale for other services
- Want simple VPN-based access
- Need stable access across network changes
Tailscale is perfect for personal use and small teams. For public access or Telegram Mini App, consider Relay or Cloudflare Tunnel.
Next steps
Runner Setup
Enable remote session spawning
Telegram Setup
Configure Telegram (requires HTTPS)