Merge pull request #21 from metgen/main

Fix typo, some improvements and adding traefik configuration for use as reverse-proxy for sub-page
This commit is contained in:
Yury Kastov
2025-03-19 05:46:32 +03:00
committed by GitHub
2 changed files with 64 additions and 6 deletions

View File

@@ -193,7 +193,7 @@ http:
entrypoints:
- http
middlewares:
- remnawave-redirect
- remnawave-https-redirect
service: remnawave
remnawave-secure:
@@ -207,7 +207,7 @@ http:
service: remnawave
middlewares:
remnawave-redirect:
remnawave-https-redirect:
redirectScheme:
scheme: https
@@ -256,7 +256,7 @@ Cloudflare regularly updates its IP ranges. To do this, you can use the [officia
:::
```yaml title="remnawave.yml"
```yaml title="ip_allow_list.yml"
http:
middlewares:
ip-allow-list:
@@ -285,6 +285,12 @@ http:
Then you need to connect the middleware `ip-allow-list` to the configuration file `remnawave.yml`
```bash
nano remnawave.yml.yml
```
Pay attention to the green line, they are the ones you need to add.
```yaml title="remnawave.yml"
http:
routers:
@@ -293,7 +299,7 @@ http:
entrypoints:
- http
middlewares:
- remnawave-redirect
- remnawave-https-redirect
service: remnawave
remnawave-secure:
@@ -301,14 +307,14 @@ http:
entrypoints:
- https
middlewares:
// highlight-next-line-yellow
// highlight-next-line-green
- ip-allow-list
tls:
certResolver: letsencrypt
service: remnawave
middlewares:
remnawave-redirect:
remnawave-https-redirect:
redirectScheme:
scheme: https

View File

@@ -247,6 +247,58 @@ Now, you need to restart Nginx container.
docker compose down && docker compose up -d && docker compose logs -f
```
### Traefik
If you have already configured Traefik, you need create a new dynamic configuration file `remnawave-sub-page.yml` in the `~/remnawave/traefik/config` folder.
```bash
cd ~/remnawave/traefik/config && nano remnawave-sub-page.yml
```
Paste the following configuration.
:::warning
Please, replace `SUBSCRIPTION_PAGE_DOMAIN` with your subscription page domain name.
Review configuration below, look for yellow highlighted lines.
:::
```yaml title="remnawave-sub-page.yml"
http:
routers:
remnawave-sub-page:
// highlight-next-line-yellow
rule: "Host(`SUBSCRIPTION_PAGE_DOMAIN`)"
entrypoints:
- http
middlewares:
- remnawave-sub-page-https-redirect
service: remnawave-sub-page
remnawave-sub-page-secure:
// highlight-next-line-yellow
rule: "Host(`SUBSCRIPTION_PAGE_DOMAIN`)"
entrypoints:
- https
middlewares:
tls:
certResolver: letsencrypt
service: remnawave-sub-page
middlewares:
remnawave-sub-page-https-redirect:
redirectScheme:
scheme: https
services:
remnawave-sub-page:
loadBalancer:
servers:
- url: "http://remnawave-subscription-page:3010"
```
## Usage
Now, you can use subscription templates.