From a877ca79ffd474803a0a48787eb18f8e3556a148 Mon Sep 17 00:00:00 2001
From: Bernd Storath <999999bst@gmail.com>
Date: Tue, 15 Apr 2025 10:35:59 +0200
Subject: [PATCH] improve docs and formatting
---
.vscode/extensions.json | 3 +-
.vscode/settings.json | 5 +
README.md | 2 +-
docs/.prettierrc.json | 5 +
docs/content/advanced/api.md | 5 +
docs/content/advanced/metrics/prometheus.md | 18 +--
.../examples/tutorials/auto-updates.md | 14 +-
.../examples/tutorials/basic-installation.md | 21 +--
docs/content/examples/tutorials/podman-nft.md | 12 +-
.../examples/tutorials/reverse-proxyless.md | 31 ++++
docs/content/examples/tutorials/traefik.md | 146 +++++++++---------
docs/content/faq.md | 60 +++----
docs/content/getting-started.md | 46 ++----
docs/content/guides/2fa.md | 23 ++-
docs/content/guides/account.md | 5 -
docs/content/guides/clients.md | 47 +++++-
docs/content/guides/login.md | 5 -
docs/content/index.md | 2 +-
docs/mkdocs.yml | 146 +++++++++---------
19 files changed, 338 insertions(+), 258 deletions(-)
create mode 100644 docs/.prettierrc.json
create mode 100644 docs/content/examples/tutorials/reverse-proxyless.md
delete mode 100644 docs/content/guides/account.md
delete mode 100644 docs/content/guides/login.md
diff --git a/.vscode/extensions.json b/.vscode/extensions.json
index 9a3a0def..aa6b587c 100644
--- a/.vscode/extensions.json
+++ b/.vscode/extensions.json
@@ -9,6 +9,7 @@
"yoavbls.pretty-ts-errors",
"bradlc.vscode-tailwindcss",
"vue.volar",
- "lokalise.i18n-ally"
+ "lokalise.i18n-ally",
+ "DavidAnson.vscode-markdownlint"
]
}
diff --git a/.vscode/settings.json b/.vscode/settings.json
index a1205250..cb4dd2f9 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -18,6 +18,11 @@
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
+ "[markdown]": {
+ "editor.defaultFormatter": "esbenp.prettier-vscode",
+ "editor.tabSize": 4,
+ "editor.useTabStops": false
+ },
"typescript.tsdk": "./src/node_modules/typescript/lib",
"i18n-ally.enabledFrameworks": ["vue"],
"i18n-ally.localesPaths": ["src/i18n/locales"],
diff --git a/README.md b/README.md
index cb729232..5042bc92 100644
--- a/README.md
+++ b/README.md
@@ -81,7 +81,7 @@ The easiest way to run WireGuard Easy is with Docker Compose.
Just download [`docker-compose.yml`](docker-compose.yml) and execute `sudo docker compose up -d`.
-Now setup a reverse proxy to be able to access the Web UI from the internet.
+Now setup a reverse proxy to be able to access the Web UI securely from the internet.
If you want to access the Web UI over HTTP, change the env var `INSECURE` to `true`. This is not recommended. Only use this for testing
diff --git a/docs/.prettierrc.json b/docs/.prettierrc.json
new file mode 100644
index 00000000..b327bd07
--- /dev/null
+++ b/docs/.prettierrc.json
@@ -0,0 +1,5 @@
+{
+ "tabWidth": 4,
+ "semi": true,
+ "singleQuote": true
+}
diff --git a/docs/content/advanced/api.md b/docs/content/advanced/api.md
index a41ea66c..58d5df2d 100644
--- a/docs/content/advanced/api.md
+++ b/docs/content/advanced/api.md
@@ -2,6 +2,11 @@
title: API
---
+/// warning | Breaking Changes
+
+This API is not yet stable and may change in the future. The API is currently in development and is subject to change without notice. The API is not yet documented, but we will add documentation as the API stabilizes.
+///
+
You can use the API to interact with the application programmatically. The API is available at `/api` and supports both GET and POST requests. The API is designed to be simple and easy to use, with a focus on providing a consistent interface for all endpoints.
There is no documentation for the API yet, but this will be added as the underlying library supports it.
diff --git a/docs/content/advanced/metrics/prometheus.md b/docs/content/advanced/metrics/prometheus.md
index 8ce6574b..09ad087b 100644
--- a/docs/content/advanced/metrics/prometheus.md
+++ b/docs/content/advanced/metrics/prometheus.md
@@ -16,15 +16,15 @@ You need to add a scrape config to your Prometheus configuration file. Here is a
```yaml
scrape_configs:
- - job_name: "wg-easy"
- scrape_interval: 30s
- metrics_path: /metrics/prometheus
- static_configs:
- - targets:
- - "localhost:51821"
- authorization:
- type: Bearer
- credentials: "SuperSecurePassword"
+ - job_name: 'wg-easy'
+ scrape_interval: 30s
+ metrics_path: /metrics/prometheus
+ static_configs:
+ - targets:
+ - 'localhost:51821'
+ authorization:
+ type: Bearer
+ credentials: 'SuperSecurePassword'
```
## Grafana Dashboard
diff --git a/docs/content/examples/tutorials/auto-updates.md b/docs/content/examples/tutorials/auto-updates.md
index fd655735..2386e2b6 100644
--- a/docs/content/examples/tutorials/auto-updates.md
+++ b/docs/content/examples/tutorials/auto-updates.md
@@ -19,13 +19,13 @@ File: `/etc/docker/containers/watchtower/docker-compose.yml`
```yaml
services:
- watchtower:
- image: containrrr/watchtower:latest
- volumes:
- - /var/run/docker.sock:/var/run/docker.sock
- env_file:
- - watchtower.env
- restart: unless-stopped
+ watchtower:
+ image: containrrr/watchtower:latest
+ volumes:
+ - /var/run/docker.sock:/var/run/docker.sock
+ env_file:
+ - watchtower.env
+ restart: unless-stopped
```
File: `/etc/docker/containers/watchtower/watchtower.env`
diff --git a/docs/content/examples/tutorials/basic-installation.md b/docs/content/examples/tutorials/basic-installation.md
index f4e5c1be..838cc6ea 100644
--- a/docs/content/examples/tutorials/basic-installation.md
+++ b/docs/content/examples/tutorials/basic-installation.md
@@ -19,22 +19,22 @@ Follow the Docs here: and install Dock
1. Create a directory for the configuration files (you can choose any directory you like):
- ```shell
- sudo mkdir -p /etc/docker/containers/wg-easy
- ```
+ ```shell
+ sudo mkdir -p /etc/docker/containers/wg-easy
+ ```
2. Download docker compose file
- ```shell
- sudo curl -o /etc/docker/containers/wg-easy/docker-compose.yml https://raw.githubusercontent.com/wg-easy/wg-easy/master/docker-compose.yml
- ```
+ ```shell
+ sudo curl -o /etc/docker/containers/wg-easy/docker-compose.yml https://raw.githubusercontent.com/wg-easy/wg-easy/master/docker-compose.yml
+ ```
3. Start `wg-easy`
- ```shell
- cd /etc/docker/containers/wg-easy
- sudo docker-compose up -d
- ```
+ ```shell
+ cd /etc/docker/containers/wg-easy
+ sudo docker-compose up -d
+ ```
## Setup Firewall
@@ -48,6 +48,7 @@ These ports can be changed, so if you change them you have to update your firewa
- To setup traefik follow the instructions here: [Traefik](./traefik.md)
- To setup caddy follow the instructions here: [Caddy](./caddy.md)
+- If you do not want to use a reverse proxy follow the instructions here: [No Reverse Proxy](./reverse-proxyless.md)
## Update `wg-easy`
diff --git a/docs/content/examples/tutorials/podman-nft.md b/docs/content/examples/tutorials/podman-nft.md
index df992070..31141a61 100644
--- a/docs/content/examples/tutorials/podman-nft.md
+++ b/docs/content/examples/tutorials/podman-nft.md
@@ -87,15 +87,15 @@ In the Admin Panel of your WireGuard server, go to the `Hooks` tab and add the f
1. PostUp
- ```shell
- nft add table inet wg_table; nft add chain inet wg_table prerouting { type nat hook prerouting priority 100 \; }; nft add chain inet wg_table postrouting { type nat hook postrouting priority 100 \; }; nft add rule inet wg_table postrouting ip saddr {{ipv4Cidr}} oifname {{device}} masquerade; nft add rule inet wg_table postrouting ip6 saddr {{ipv6Cidr}} oifname {{device}} masquerade; nft add chain inet wg_table input { type filter hook input priority 0 \; policy accept \; }; nft add rule inet wg_table input udp dport {{port}} accept; nft add rule inet wg_table input tcp dport {{uiPort}} accept; nft add chain inet wg_table forward { type filter hook forward priority 0 \; policy accept \; }; nft add rule inet wg_table forward iifname "wg0" accept; nft add rule inet wg_table forward oifname "wg0" accept;
- ```
+ ```shell
+ nft add table inet wg_table; nft add chain inet wg_table prerouting { type nat hook prerouting priority 100 \; }; nft add chain inet wg_table postrouting { type nat hook postrouting priority 100 \; }; nft add rule inet wg_table postrouting ip saddr {{ipv4Cidr}} oifname {{device}} masquerade; nft add rule inet wg_table postrouting ip6 saddr {{ipv6Cidr}} oifname {{device}} masquerade; nft add chain inet wg_table input { type filter hook input priority 0 \; policy accept \; }; nft add rule inet wg_table input udp dport {{port}} accept; nft add rule inet wg_table input tcp dport {{uiPort}} accept; nft add chain inet wg_table forward { type filter hook forward priority 0 \; policy accept \; }; nft add rule inet wg_table forward iifname "wg0" accept; nft add rule inet wg_table forward oifname "wg0" accept;
+ ```
2. PostDown
- ```shell
- nft delete table inet wg_table
- ```
+ ```shell
+ nft delete table inet wg_table
+ ```
If you don't have iptables loaded on your server, you could see many errors in the logs or in the UI. You can ignore them.
diff --git a/docs/content/examples/tutorials/reverse-proxyless.md b/docs/content/examples/tutorials/reverse-proxyless.md
new file mode 100644
index 00000000..346d8c29
--- /dev/null
+++ b/docs/content/examples/tutorials/reverse-proxyless.md
@@ -0,0 +1,31 @@
+---
+title: No Reverse Proxy
+---
+
+# asd
+
+/// warning | Insecure
+
+This is insecure. You should use a reverse proxy to secure the connection.
+
+Only use this method if you know what you are doing.
+///
+
+If you only allow access to the web UI from your local network, you can skip the reverse proxy setup. This is not recommended, but it is possible.
+
+## Setup
+
+- Edit the `docker-compose.yml` file and uncomment `environment` and `INSECURE`
+
+- Set `INSECURE` to `true` to allow access to the web UI over a non-secure connection.
+
+- The `docker-compose.yml` file should look something like this:
+
+ ```yaml
+ environment:
+ - INSECURE=true
+ ```
+
+- Save the file and restart `wg-easy`.
+
+- Make sure that the Web UI is not accessible from outside your local network.
diff --git a/docs/content/examples/tutorials/traefik.md b/docs/content/examples/tutorials/traefik.md
index 6bbed1e4..3e37bee6 100644
--- a/docs/content/examples/tutorials/traefik.md
+++ b/docs/content/examples/tutorials/traefik.md
@@ -20,25 +20,25 @@ File: `/etc/docker/containers/traefik/docker-compose.yml`
```yaml
services:
- traefik:
- image: traefik:3.3
- container_name: traefik
- restart: unless-stopped
- ports:
- - "80:80"
- - "443:443/tcp"
- - "443:443/udp"
- volumes:
- - /var/run/docker.sock:/var/run/docker.sock
- - /etc/docker/volumes/traefik/traefik.yml:/traefik.yml:ro
- - /etc/docker/volumes/traefik/traefik_dynamic.yml:/traefik_dynamic.yml:ro
- - /etc/docker/volumes/traefik/acme.json:/acme.json
- networks:
- - traefik
+ traefik:
+ image: traefik:3.3
+ container_name: traefik
+ restart: unless-stopped
+ ports:
+ - '80:80'
+ - '443:443/tcp'
+ - '443:443/udp'
+ volumes:
+ - /var/run/docker.sock:/var/run/docker.sock
+ - /etc/docker/volumes/traefik/traefik.yml:/traefik.yml:ro
+ - /etc/docker/volumes/traefik/traefik_dynamic.yml:/traefik_dynamic.yml:ro
+ - /etc/docker/volumes/traefik/acme.json:/acme.json
+ networks:
+ - traefik
networks:
- traefik:
- external: true
+ traefik:
+ external: true
```
## Create traefik.yml
@@ -47,47 +47,47 @@ File: `/etc/docker/volumes/traefik/traefik.yml`
```yaml
log:
- level: INFO
+ level: INFO
entryPoints:
- web:
- address: ":80/tcp"
- http:
- redirections:
- entryPoint:
- to: websecure
- scheme: https
- websecure:
- address: ":443/tcp"
- http:
- middlewares:
- - compress@file
- - hsts@file
- tls:
- certResolver: letsencrypt
- http3: {}
+ web:
+ address: ':80/tcp'
+ http:
+ redirections:
+ entryPoint:
+ to: websecure
+ scheme: https
+ websecure:
+ address: ':443/tcp'
+ http:
+ middlewares:
+ - compress@file
+ - hsts@file
+ tls:
+ certResolver: letsencrypt
+ http3: {}
api:
- dashboard: true
+ dashboard: true
certificatesResolvers:
- letsencrypt:
- acme:
- email: $mail@example.com$
- storage: acme.json
- httpChallenge:
- entryPoint: web
+ letsencrypt:
+ acme:
+ email: $mail@example.com$
+ storage: acme.json
+ httpChallenge:
+ entryPoint: web
providers:
- docker:
- watch: true
- network: traefik
- exposedByDefault: false
- file:
- filename: traefik_dynamic.yml
+ docker:
+ watch: true
+ network: traefik
+ exposedByDefault: false
+ file:
+ filename: traefik_dynamic.yml
serversTransport:
- insecureSkipVerify: true
+ insecureSkipVerify: true
```
## Create traefik_dynamic.yml
@@ -96,33 +96,33 @@ File: `/etc/docker/volumes/traefik/traefik_dynamic.yml`
```yaml
http:
- middlewares:
- services:
- basicAuth:
- users:
- - "$username$:$password$"
- compress:
- compress: {}
- hsts:
- headers:
- stsSeconds: 2592000
- routers:
- api:
- rule: Host(`traefik.$example.com$`)
- entrypoints:
- - websecure
- middlewares:
- - services
- service: api@internal
+ middlewares:
+ services:
+ basicAuth:
+ users:
+ - '$username$:$password$'
+ compress:
+ compress: {}
+ hsts:
+ headers:
+ stsSeconds: 2592000
+ routers:
+ api:
+ rule: Host(`traefik.$example.com$`)
+ entrypoints:
+ - websecure
+ middlewares:
+ - services
+ service: api@internal
tls:
- options:
- default:
- cipherSuites:
- - TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
- - TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
- - TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256
- sniStrict: true
+ options:
+ default:
+ cipherSuites:
+ - TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
+ - TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
+ - TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256
+ sniStrict: true
```
## Create acme.json
diff --git a/docs/content/faq.md b/docs/content/faq.md
index ec321e0f..7fd0cd12 100644
--- a/docs/content/faq.md
+++ b/docs/content/faq.md
@@ -1,7 +1,7 @@
---
title: FAQ
hide:
- - navigation
+ - navigation
---
Here are some frequently asked questions or errors about `wg-easy`. If you have a question that is not answered here, please feel free to open a discussion on GitHub.
@@ -14,15 +14,15 @@ To resolve this issue, you can try the following steps:
1. **Load the WireGuard kernel module**: If the WireGuard kernel module is not loaded, you can load it manually by running:
- ```bash
+ ```bash
sudo modprobe wireguard
- ```
+ ```
2. **Load the WireGuard kernel module on boot**: If you want to ensure that the WireGuard kernel module is loaded automatically on boot, you can add it to the `/etc/modules` file:
- ```bash
- echo "wireguard" | sudo tee -a /etc/modules
- ```
+ ```bash
+ echo "wireguard" | sudo tee -a /etc/modules
+ ```
## can't initialize iptables table `nat': Table does not exist (do you need to insmod?)
@@ -32,15 +32,15 @@ To resolve this issue, you can try the following steps:
1. **Load the `nat` kernel module**: If the `nat` kernel module is not loaded, you can load it manually by running:
- ```bash
- sudo modprobe iptable_nat
- ```
+ ```bash
+ sudo modprobe iptable_nat
+ ```
2. **Load the `nat` kernel module on boot**: If you want to ensure that the `nat` kernel module is loaded automatically on boot, you can add it to the `/etc/modules` file:
- ```bash
- echo "iptable_nat" | sudo tee -a /etc/modules
- ```
+ ```bash
+ echo "iptable_nat" | sudo tee -a /etc/modules
+ ```
## can't initialize ip6tables table `nat': Table does not exist (do you need to insmod?)
@@ -50,15 +50,15 @@ To resolve this issue, you can try the following steps:
1. **Load the `nat` kernel module**: If the `nat` kernel module is not loaded, you can load it manually by running:
- ```bash
- sudo modprobe ip6table_nat
- ```
+ ```bash
+ sudo modprobe ip6table_nat
+ ```
2. **Load the `nat` kernel module on boot**: If you want to ensure that the `nat` kernel module is loaded automatically on boot, you can add it to the `/etc/modules` file:
- ```bash
- echo "ip6table_nat" | sudo tee -a /etc/modules
- ```
+ ```bash
+ echo "ip6table_nat" | sudo tee -a /etc/modules
+ ```
## can't initialize iptables table `filter': Permission denied
@@ -68,15 +68,15 @@ To resolve this issue, you can try the following steps:
1. **Load the `filter` kernel module**: If the `filter` kernel module is not loaded, you can load it manually by running:
- ```bash
- sudo modprobe iptable_filter
- ```
+ ```bash
+ sudo modprobe iptable_filter
+ ```
2. **Load the `filter` kernel module on boot**: If you want to ensure that the `filter` kernel module is loaded automatically on boot, you can add it to the `/etc/modules` file:
- ```bash
- echo "iptable_filter" | sudo tee -a /etc/modules
- ```
+ ```bash
+ echo "iptable_filter" | sudo tee -a /etc/modules
+ ```
## can't initialize ip6tables table `filter': Permission denied
@@ -86,12 +86,12 @@ To resolve this issue, you can try the following steps:
1. **Load the `filter` kernel module**: If the `filter` kernel module is not loaded, you can load it manually by running:
- ```bash
- sudo modprobe ip6table_filter
- ```
+ ```bash
+ sudo modprobe ip6table_filter
+ ```
2. **Load the `filter` kernel module on boot**: If you want to ensure that the `filter` kernel module is loaded automatically on boot, you can add it to the `/etc/modules` file:
- ```bash
- echo "ip6table_filter" | sudo tee -a /etc/modules
- ```
+ ```bash
+ echo "ip6table_filter" | sudo tee -a /etc/modules
+ ```
diff --git a/docs/content/getting-started.md b/docs/content/getting-started.md
index 759d5176..8baa9d03 100644
--- a/docs/content/getting-started.md
+++ b/docs/content/getting-started.md
@@ -1,7 +1,7 @@
---
title: Getting Started
hide:
- - navigation
+ - navigation
---
This page explains how to get started with `wg-easy`. The guide uses Docker Compose as a reference. In our examples, we mount the named volume `etc_wireguard` to `/etc/wireguard` inside the container.
@@ -43,54 +43,30 @@ All workflows are using the tagging convention listed below. It is subsequently
| tag | Type | Example | Description |
| ------------- | ---------------------------------------------------------- | ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
-| `15` | latest minor for that major tag | `ghcr.io/wg-easy/wg-easy:15` | latest features for specific major versions, no breaking changes |
-| `latest` | latest tag | `ghcr.io/wg-easy/wg-easy:latest` or `ghcr.io/wg-easy/wg-easy` | stable as possible get bug fixes quickly when needed, see Releases for more information. |
+| `15` | latest minor for that major tag | `ghcr.io/wg-easy/wg-easy:15` | latest features for specific major versions, no breaking changes, recommended |
+| `latest` | latest tag | `ghcr.io/wg-easy/wg-easy:latest` or `ghcr.io/wg-easy/wg-easy` | points to latest release, can include breaking changes |
| `15.0` | latest patch for that minor tag | `ghcr.io/wg-easy/wg-easy:15.0` | latest patches for specific minor version |
-| `15.0.0` | specific tag | `ghcr.io/wg-easy/wg-easy:15.0.0` | specific release, don't use this as this will not get updated |
+| `15.0.0` | specific tag | `ghcr.io/wg-easy/wg-easy:15.0.0` | specific release, no updates |
| `nightly` | [`master`](https://github.com/wg-easy/wg-easy/tree/master) | `ghcr.io/wg-easy/wg-easy:nightly` | mostly unstable gets frequent package and code updates, deployed against [`master`](https://github.com/wg-easy/wg-easy/tree/master). |
| `development` | pull requests | `ghcr.io/wg-easy/wg-easy:development` | used for development, testing code from PRs before landing into [`master`](https://github.com/wg-easy/wg-easy/tree/master). |
+
+
When publishing a tag we follow the [Semantic Versioning][semver] specification. The `latest` tag is always pointing to the latest stable release. If you want to avoid breaking changes, use the major version tag (e.g. `15`).
[github-ci]: https://github.com/wg-easy/wg-easy/actions
[ghcr-image]: https://github.com/wg-easy/wg-easy/pkgs/container/wg-easy
[semver]: https://semver.org/
-### Get All Files
-
-Issue the following command to acquire the necessary file:
-
-```shell
-wget "https://raw.githubusercontent.com/wg-easy/wg-easy/master/docker-compose.yml"
-```
-
-### Start the Container
-
-To start the container, issue the following command:
-
-```shell
-sudo docker compose up -d
-```
+### Follow tutorials
-### Configuration Steps
+- [Basic Installation with Docker Compose (Recommended)](./examples/tutorials/basic-installation.md)
+- [Simple Installation with Docker Run](./examples/tutorials/docker-run.md)
+- [Advanced Installation with Podman](./examples/tutorials/podman-nft.md)
-Now follow the setup process in your web browser
-
-### Stopping the Container
-
-To stop the container, issue the following command:
-
-```shell
-sudo docker compose down
-```
-
-/// danger | Using the Correct Commands For Stopping and Starting `wg-easy`
+/// danger | Use the Correct Commands For Stopping and Starting `wg-easy`
**Use `sudo docker compose up / down`, not `sudo docker compose start / stop`**. Otherwise, the container is not properly destroyed and you may experience problems during startup because of inconsistent state.
///
**That's it! It really is that easy**.
-
-If you need more help you can read the [Basic Installation Tutorial][basic-installation].
-
-[basic-installation]: ./examples/tutorials/basic-installation.md
diff --git a/docs/content/guides/2fa.md b/docs/content/guides/2fa.md
index 3db179f1..f69a0eb6 100644
--- a/docs/content/guides/2fa.md
+++ b/docs/content/guides/2fa.md
@@ -2,4 +2,25 @@
title: 2FA
---
-TODO
+The user can enable 2FA from the Account page. The Account page is accessible from the dropdown menu in the top right corner of the application.
+
+## Enable TOTP
+
+- **Enable Two Factor Authentication**: Enable TOTP for the user.
+
+## Configure TOTP
+
+A QR code will be displayed. Scan the QR code with your TOTP application (e.g., Google Authenticator, Authy, etc.) to add the account.
+
+To verify that the TOTP key is working, the user must enter the TOTP code generated by the TOTP application.
+
+- **TOTP Key**: The TOTP key for the user. This key is used to generate the TOTP code.
+- **TOTP Code**: The current TOTP code for the user. This code is used to verify the TOTP key.
+- **Enable Two Factor Authentication**: Enable TOTP for the user.
+
+## Disable TOTP
+
+To disable TOTP, the user must enter the current password.
+
+- **Current Password**: The current password of the user.
+- **Disable Two Factor Authentication**: Disable TOTP for the user.
diff --git a/docs/content/guides/account.md b/docs/content/guides/account.md
deleted file mode 100644
index 6728c816..00000000
--- a/docs/content/guides/account.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-title: Edit Account
----
-
-TODO
diff --git a/docs/content/guides/clients.md b/docs/content/guides/clients.md
index d1776ba2..7d730f1b 100644
--- a/docs/content/guides/clients.md
+++ b/docs/content/guides/clients.md
@@ -2,4 +2,49 @@
title: Edit Client
---
-TODO
+## General
+
+- **Name**: The name of the client.
+- **Enabled**: Whether the client can connect to the VPN.
+- **Expire Date**: The date the client will be disabled.
+
+## Address
+
+- **IPv4**: The IPv4 address of the client.
+- **IPv6**: The IPv6 address of the client.
+
+## Allowed IPs
+
+Which IPs will be routed through the VPN.
+
+This will not prevent the user from modifing it locally and accessing IP ranges that they should not be able to access.
+
+Use firewall rules to prevent access to IP ranges that the user should not be able to access.
+
+## Server Allowed IPs
+
+Which IPs will be routed to the client.
+
+## DNS
+
+The DNS server that the client will use.
+
+## Advanced
+
+- **MTU**: The maximum transmission unit for the client.
+- **Persistent Keepalive**: The interval for sending keepalive packets to the server.
+
+## Hooks
+
+This can only be used for clients that use `wg-quick`. Setting this will throw a error when importing the config on other clients.
+
+- **PreUp**: Commands to run before the interface is brought up.
+- **PostUp**: Commands to run after the interface is brought up.
+- **PreDown**: Commands to run before the interface is brought down.
+- **PostDown**: Commands to run after the interface is brought down.
+
+## Actions
+
+- **Save**: Save the changes made in the form.
+- **Revert**: Revert the changes made in the form.
+- **Delete**: Delete the client.
diff --git a/docs/content/guides/login.md b/docs/content/guides/login.md
deleted file mode 100644
index e41e7ea3..00000000
--- a/docs/content/guides/login.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-title: Login
----
-
-TODO
diff --git a/docs/content/index.md b/docs/content/index.md
index ae9b30f1..2e2c3235 100644
--- a/docs/content/index.md
+++ b/docs/content/index.md
@@ -1,7 +1,7 @@
---
title: Home
hide:
- - navigation
+ - navigation
---
# Welcome to the Documentation for `wg-easy`
diff --git a/docs/mkdocs.yml b/docs/mkdocs.yml
index 1050003e..5247b1c8 100644
--- a/docs/mkdocs.yml
+++ b/docs/mkdocs.yml
@@ -1,87 +1,87 @@
-site_name: "wg-easy"
-site_description: "The easiest way to run WireGuard VPN + Web-based Admin UI."
-site_author: "WireGuard Easy"
+site_name: 'wg-easy'
+site_description: 'The easiest way to run WireGuard VPN + Web-based Admin UI.'
+site_author: 'WireGuard Easy'
copyright: >
-
- © Wireguard Easy
- This project is licensed under AGPL-3.0-only.
- This project is not affiliated, associated, authorized, endorsed by, or in any way officially connected with Jason A. Donenfeld, ZX2C4 or Edge Security
- "WireGuard" and the "WireGuard" logo are registered trademarks of Jason A. Donenfeld
-
+
+ © Wireguard Easy
+ This project is licensed under AGPL-3.0-only.
+ This project is not affiliated, associated, authorized, endorsed by, or in any way officially connected with Jason A. Donenfeld, ZX2C4 or Edge Security
+ "WireGuard" and the "WireGuard" logo are registered trademarks of Jason A. Donenfeld
+
repo_url: https://github.com/wg-easy/wg-easy
repo_name: wg-easy
-edit_uri: "edit/master/docs/content"
+edit_uri: 'edit/master/docs/content'
-docs_dir: "content/"
+docs_dir: 'content/'
site_url: https://wg-easy.github.io/wg-easy
theme:
- name: material
- favicon: assets/logo/favicon.png
- logo: assets/logo/logo.png
- icon:
- repo: fontawesome/brands/github
- features:
- - navigation.tabs
- - navigation.top
- - navigation.expand
- - navigation.instant
- - content.action.edit
- - content.action.view
- - content.code.annotate
- palette:
- # Light mode
- - media: "(prefers-color-scheme: light)"
- scheme: default
- primary: grey
- accent: red
- toggle:
- icon: material/weather-night
- name: Switch to dark mode
- # Dark mode
- - media: "(prefers-color-scheme: dark)"
- scheme: slate
- primary: grey
- accent: red
- toggle:
- icon: material/weather-sunny
- name: Switch to light mode
+ name: material
+ favicon: assets/logo/favicon.png
+ logo: assets/logo/logo.png
+ icon:
+ repo: fontawesome/brands/github
+ features:
+ - navigation.tabs
+ - navigation.top
+ - navigation.expand
+ - navigation.instant
+ - content.action.edit
+ - content.action.view
+ - content.code.annotate
+ palette:
+ # Light mode
+ - media: '(prefers-color-scheme: light)'
+ scheme: default
+ primary: grey
+ accent: red
+ toggle:
+ icon: material/weather-night
+ name: Switch to dark mode
+ # Dark mode
+ - media: '(prefers-color-scheme: dark)'
+ scheme: slate
+ primary: grey
+ accent: red
+ toggle:
+ icon: material/weather-sunny
+ name: Switch to light mode
extra:
- version:
- provider: mike
+ version:
+ provider: mike
markdown_extensions:
- - toc:
- anchorlink: true
- - abbr
- - attr_list
- - pymdownx.blocks.admonition:
- types:
- - danger
- - note
- - info
- - question
- - warning
- - pymdownx.details
- - pymdownx.superfences:
- custom_fences:
- - name: mermaid
- class: mermaid
- format: !!python/name:pymdownx.superfences.fence_code_format
- - pymdownx.tabbed:
- alternate_style: true
- slugify: !!python/object/apply:pymdownx.slugs.slugify
- kwds:
- case: lower
- - pymdownx.tasklist:
- custom_checkbox: true
- - pymdownx.magiclink
- - pymdownx.inlinehilite
- - pymdownx.tilde
- - pymdownx.emoji:
- emoji_index: !!python/name:material.extensions.emoji.twemoji
- emoji_generator: !!python/name:material.extensions.emoji.to_svg
+ - toc:
+ anchorlink: true
+ - abbr
+ - attr_list
+ - pymdownx.blocks.admonition:
+ types:
+ - danger
+ - note
+ - info
+ - question
+ - warning
+ - pymdownx.details
+ - pymdownx.superfences:
+ custom_fences:
+ - name: mermaid
+ class: mermaid
+ format: !!python/name:pymdownx.superfences.fence_code_format
+ - pymdownx.tabbed:
+ alternate_style: true
+ slugify: !!python/object/apply:pymdownx.slugs.slugify
+ kwds:
+ case: lower
+ - pymdownx.tasklist:
+ custom_checkbox: true
+ - pymdownx.magiclink
+ - pymdownx.inlinehilite
+ - pymdownx.tilde
+ - pymdownx.emoji:
+ emoji_index: !!python/name:material.extensions.emoji.twemoji
+ emoji_generator: !!python/name:material.extensions.emoji.to_svg