wireadmin/README.md

94 lines
3.8 KiB
Markdown
Raw Normal View History

# WireGuard GUI (Easy Admin UI)
2023-09-29 05:55:03 +00:00
![Screenshot](assets/screenshot-1.png)
2023-12-21 21:34:25 +00:00
| | | |
2024-04-20 20:25:11 +00:00
| :----------------------------------------------------------------------------------------: | :----------------------------------------------------------------------------------------: | :----------------------------------------------------------------------------------------: |
2023-12-21 21:34:25 +00:00
| <img src="assets/screenshot-2.png" alt="screenshot" style="width:100%;max-height:300px;"/> | <img src="assets/screenshot-4.png" alt="screenshot" style="width:100%;max-height:300px;"/> | <img src="assets/screenshot-3.png" alt="screenshot" style="width:100%;max-height:300px;"/> |
2023-09-29 05:55:03 +00:00
## Features
- Easy-to-use web-based admin UI
- Support for multiple users and servers
2023-12-01 15:18:46 +00:00
- Support for **Tor for anonymized connections**
2023-09-29 05:55:03 +00:00
- List, create, delete, or modify any server or user
- Scan QR codes or easily download the client configurations.
## Installation
2024-04-20 20:25:11 +00:00
### 1. Prerequisites
2023-09-29 05:55:03 +00:00
2024-04-20 20:25:11 +00:00
- [Docker Engine](https://docs.docker.com/engine/install/)
2023-09-29 05:55:03 +00:00
2023-11-08 17:05:45 +00:00
### 2. Persistent Data
2024-04-20 20:25:11 +00:00
WireAdmin store configurations at `/data`. It's important to mount a volume at this location to ensure that
your data is not lost during container restarts or updates.
2023-11-08 17:05:45 +00:00
#### Create a docker volume
```bash
docker volume create wireadmin-data --driver local
```
2024-04-20 20:25:11 +00:00
### 3. Download Image
2023-09-29 05:55:03 +00:00
2024-04-20 20:25:11 +00:00
#### Build from source
```bash
git clone https://github.com/shahradelahi/wireadmin
docker buildx build --tag litehex/wireadmin .
```
#### Pull from Docker Hub (recommended)
```bash
docker pull litehex/wireadmin
```
### 4. Run
When creating each server, ensure that you add the port exposure through Docker. In the below command, the port `51820`
is added for the WireGuard server.
**NOTE:** The port `3000` is for the WebUI, and can be changed with `PORT` environment variable, but for security
reasons, it's recommended to NOT expose **_any kind of WebUI_** to the public. It's up to you to remove it after
configuring
the Servers/Peers.
2023-09-29 05:55:03 +00:00
```bash
2023-12-01 15:18:46 +00:00
docker run --rm \
2024-01-24 15:32:47 +00:00
-e WG_HOST=<YOUR_SERVER_IP> \
-e UI_PASSWORD=<ADMIN_PASSWORD> \
2023-09-29 05:55:03 +00:00
-p "3000:3000/tcp" \
-p "51820:51820/udp" \
2023-11-08 17:05:45 +00:00
-v "wireadmin-data:/data" \
2023-09-29 05:55:03 +00:00
--cap-add=NET_ADMIN \
--cap-add=SYS_MODULE \
--sysctl="net.ipv4.conf.all.src_valid_mark=1" \
2023-10-15 15:38:59 +00:00
--sysctl="net.ipv4.ip_forward=1" \
2024-04-20 20:25:11 +00:00
litehex/wireadmin
2023-09-29 05:55:03 +00:00
```
## Environment Options
These options can be configured by setting environment variables using `-e KEY="VALUE"` in the `docker run` command.
2024-04-20 20:25:11 +00:00
| Option | Description | Optional |
| ----------------- | ------------------------------------------------------------------------------- | -------- |
| `WG_HOST` | The public IP address of the WireGuard server. | |
| `UI_PASSWORD` | The password for the admin UI. | |
| `HOST` | The hostname for the WebUI. (default: `127.0.0.1`) | ✔️ |
| `PORT` | The port for the WebUI. (default: `3000`) | ✔️ |
| `TOR_USE_BRIDGES` | Set this to `1` and then mount the bridges file at `/etc/torrc.d/bridges.conf`. | ✔️ |
| `TOR_*` | The `Torrc` proxy configuration. (e.g. `SocksPort` as `TOR_SOCKSPORT="9050"`) | ✔️ |
2023-09-29 05:55:03 +00:00
2023-12-12 10:04:15 +00:00
## Reporting
2024-04-20 20:25:11 +00:00
For bug reports, and feature requests, please create an issue
2023-12-12 10:04:15 +00:00
on [GitHub](https://github.com/shahradelahi/wireadmin/issues).
2023-09-29 05:55:03 +00:00
## License
2024-04-20 20:25:11 +00:00
[GPL-3.0](LICENSE) © [Shahrad Elahi](https://github.com/shahradelahi)