How 2grey/awg-openwrt works
This repository delivers AmneziaWG support for OpenWrt: kernel and userspace packages, LuCI configuration and status pages, and installation paths. The principal workflow is installing the packages, configuring an interface and peers through LuCI or the setup script, then viewing live status. The README also documents signed package feeds, configuration import/export, router diagnostics, and firewall/routing setup. Source excerpts show the LuCI protocol and status RPC calls; implementation details for the shell scripts, kernel module, and tools were not sampled, so their internal relationships are documented at the README level.
Main entry points: amneziawg-install.sh Setup installer · amneziawg.js Interface configuration · luci.amneziawg LuCI RPC service · amneziawg-feed-install.sh Feed installer
Components 16
Installation and feeds
- Signed package feed
- Feed installer
amneziawg-feed-install.sh
Tunnel runtime
- AWG tools
amneziawg-tools/files/amneziawg.sh - Interface watchdog
amneziawg-tools/files/amneziawg_watchdog - Kernel module
kmod-amneziawg - OpenWrt interface config
- Firewall and routes
LuCI management
- Interface configuration
luci-proto-amneziawg/htdocs/luci-static/resources/protocol/amneziawg.js - Legacy configuration
luci-app-amneziawg/htdocs/luci-static/resources/protocol/amneziawg.js - Live status view
luci-proto-amneziawg/htdocs/luci-static/resources/view/amneziawg/status.js - Legacy status view
luci-app-amneziawg/htdocs/luci-static/resources/view/amneziawg/status.js - LuCI RPC service
luci-proto-amneziawg/root/usr/share/rpcd/ucode/luci.amneziawg
Setup and diagnostics
- Setup installer
amneziawg-install.sh - Router diagnostics
amneziawg-check.sh
Other components
- Router operator
- OpenWrt router
Connections 20
- Router operator → Feed installer: runs installer
README.md - Feed installer → Signed package feed: installs packages
README.md - Router operator → Setup installer: runs installer
README.md - Setup installer → AWG tools: installs tools
README.md - Setup installer → Kernel module: installs module
README.md - Setup installer → OpenWrt interface config: configures interface
README.md - Setup installer → Firewall and routes: configures rules
README.md - Setup installer → Firewall and routes: routes allowed IPs
README.md - Router operator → Router diagnostics: runs check
README.md - Router operator → Interface configuration: configures VPN
README.md - Interface configuration → OpenWrt interface config: reads and writes
luci-proto-amneziawg/htdocs/luci-static/resources/protocol/amneziawg.js - Interface configuration → LuCI RPC service: requests key operations
luci-proto-amneziawg/htdocs/luci-static/resources/protocol/amneziawg.js - Router operator → Legacy configuration: configures VPN
README.md - Legacy configuration → OpenWrt interface config: reads and writes
luci-app-amneziawg/htdocs/luci-static/resources/protocol/amneziawg.js - Router operator → Live status view: views status
README.md - Live status view → LuCI RPC service: polls instances
luci-proto-amneziawg/htdocs/luci-static/resources/view/amneziawg/status.js - Router operator → Legacy status view: views status
luci-app-amneziawg/htdocs/luci-static/resources/view/amneziawg/status.js - Legacy status view → LuCI RPC service: polls instances
luci-app-amneziawg/htdocs/luci-static/resources/view/amneziawg/status.js - AWG tools → Kernel module: manages tunnel
- Interface watchdog → OpenWrt router: monitors interface