Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/MHSanaei/3x-ui.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbigbug <ibigbugcc@gmail.com>2024-08-30 10:16:13 +0300
committerGitHub <noreply@github.com>2024-08-30 10:16:13 +0300
commitc0b88fe7366fc19149c7cfc9fc80bdd32e6b32dc (patch)
treefbffc978f4ba4d8cad716a9f650a258e314be9d6 /README.md
parentfa43248e3043932a31bc93ff86a2d4a3f1314491 (diff)
Nginx reverse proxy setting (#2504)
* Nginx reverse proxy web Reverse proxy root path or subpath * Update README.md * Fix ru_RU doc translation * Fix translation issues Fix similar problems with other translations
Diffstat (limited to 'README.md')
-rw-r--r--README.md35
1 files changed, 35 insertions, 0 deletions
diff --git a/README.md b/README.md
index 33e18dfb..bf398d06 100644
--- a/README.md
+++ b/README.md
@@ -202,6 +202,41 @@ systemctl restart x-ui
</details>
+## Nginx Settings
+<details>
+ <summary>Click for Reverse Proxy Configuration</summary>
+
+#### Nginx Reverse Proxy
+```nginx
+location / {
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+ proxy_set_header X-Forwarded-Proto $scheme;
+ proxy_set_header Host $http_host;
+ proxy_set_header X-Real-IP $remote_addr;
+ proxy_set_header Range $http_range;
+ proxy_set_header If-Range $http_if_range;
+ proxy_redirect off;
+ proxy_pass http://127.0.0.1:2053;
+}
+```
+
+#### Nginx sub-path
+- Ensure that the "URI Path" in the `/sub` panel settings is the same.
+- The `url` in the panel settings needs to end with `/`.
+
+```nginx
+location /sub {
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+ proxy_set_header X-Forwarded-Proto $scheme;
+ proxy_set_header Host $http_host;
+ proxy_set_header X-Real-IP $remote_addr;
+ proxy_set_header Range $http_range;
+ proxy_set_header If-Range $http_if_range;
+ proxy_redirect off;
+ proxy_pass http://127.0.0.1:2053;
+}
+```
+</details>
## Recommended OS