How winyannainghtut/ghostlink works
Ghostlink is a self-hosted VPN with a desktop client, CLI, optional MCP bridge, and a Linux server-management plane. The main user flow imports or selects a connection profile, sends actions through the local VPN service, and runs a protocol session; server owners separately manage clients, keys, policies, monitoring, and mesh nodes through the server API and dashboard. README statements and shown excerpts support the principal links; unsampled backend internals are represented by their enclosing source directories, with uncertain wiring omitted.
Main entry points: main.rs Local service · worker_session.rs VPN engine · App.tsx Admin dashboard · server VPN server
Components 25
Client applications
- Desktop app
ui/desktop/src/App.tsx - CLI
cli/ghostlink/src/main.rs - MCP bridge
integrations/mcp-server/src/main.rs - Desktop shell
apps/desktop/src-tauri/src/main.rs
Local VPN runtime
- Local service
services/vpn-daemon/src/main.rs - Service IPC
services/vpn-daemon/src/ipc.rs - Remote server client
services/vpn-daemon/src/remote.rs - VPN engine
core/vpn-engine/src/worker_session.rs - Profiles and keys
core/vpn-engine/src/profile.rs - Outline transport
core/vpn-engine/src/outline.rs - WireGuard transport
core/vpn-engine/src/wireguard.rs - VLESS transport
core/vpn-engine/src/vless.rs - AmneziaWG transport
core/vpn-engine/src/amnezia.rs - OpenVPN support
server/openvpn
VPN server
- VPN server
core/outline-worker/internal/server - Server administration
core/vpn-engine/src/server_admin.rs - Mesh agent
core/outline-worker/internal/meshagent - Monitoring
core/outline-worker/internal/server/monitor.go
Server management
- Admin dashboard
ui/dashboard/src/App.tsx - Client management
ui/admin/views/Clients.tsx - Client keys and limits
ui/admin/views/ClientSheet.tsx - Traffic rules
ui/admin/RulesEditor.tsx - Speed limits
ui/admin/SpeedLimit.tsx - Mesh dashboard
ui/admin/views/Mesh.tsx
Other components
- VPN user
Connections 28
- VPN user → Desktop app: uses
- VPN user → CLI: uses
- VPN user → MCP bridge: may use
- Desktop app → Desktop shell: invokes IPC
- Desktop shell → Local service: forwards requests
- Desktop app → Local service: requests and polls
- CLI → Local service: controls
- MCP bridge → Local service: controls
- Local service → Service IPC: dispatches requests
services/vpn-daemon/src/main.rs - Local service → Remote server client: uses remote API
services/vpn-daemon/src/main.rs - Local service → VPN engine: starts sessions
- VPN engine → Profiles and keys: loads profile
core/vpn-engine/src/worker_session.rs - VPN engine → Outline transport: runs session
core/vpn-engine/src/worker_session.rs - VPN engine → WireGuard transport: runs session
core/vpn-engine/src/worker_session.rs - VPN engine → VLESS transport: runs session
- VPN engine → AmneziaWG transport: runs session
- VPN user → OpenVPN support: may connect
- VPN user → VPN server: connects to
- Server administration → VPN server: manages
- Mesh agent → VPN server: joins mesh
- VPN user → Admin dashboard: manages server
- Admin dashboard → Client management: shows clients
ui/dashboard/src/App.tsx - Client management → Client keys and limits: opens details
ui/admin/views/Clients.tsx - Client keys and limits → Traffic rules: uses editor
ui/admin/views/ClientSheet.tsx - Client keys and limits → Speed limits: uses limits
ui/admin/views/ClientSheet.tsx - Admin dashboard → Mesh dashboard: offers mesh view
- Admin dashboard → VPN server: requests server API
- Admin dashboard → Monitoring: displays live data