Requirements: Bash 3.2+, WireGuard wg, Python 3, Python venv/pip, qrcode[pil]. Linux automatic system dependency installation supports apt, dnf, pacman. macOS supports Homebrew.
| 1 | #!/usr/bin/env bash |
| 2 | # WireGuard client provisioning for Linux and macOS. |
| 3 | # Based on the workflow of wireguard-provision.ps1: detect dependencies, |
| 4 | # offer automatic/manual installation, ask for client details, generate |
| 5 | # <device>.conf + <device>.png locally, and print the client's public key. |
| 6 | # Usage: chmod +x wireguard-provision.sh && ./wireguard-provision.sh |
| 7 | # Menu: generate new .conf/.png, or display QR from an existing .conf. |
| 8 | # Optional: ./wireguard-provision.sh /path/to/output-directory |
| 9 | # Requirements: Bash 3.2+, WireGuard wg, Python 3, Python venv/pip, qrcode[pil]. |
| 10 | # Linux automatic system dependency installation supports apt, dnf, pacman; |