Files
obsidian/PVE/Проброс IP от NPM.md
2026-09-24 13:22:58 +05:00

25 lines
801 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
Для проброса реально IP от NPM в Nextcloud необходимо добавить в config.php следующие поля:
```
'trusted_proxies' =>
array (
0 => '192.168.88.126',
),
'forwarded_for_headers' =>
array (
0 => 'HTTP_X_FORWARDED_FOR',
),
```
При этом в сам NPM добавить следующие параметры
```
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_hide_header Upgrade;
```
В роутере (Openwrt):
создать правило NAT, которое бы разрешало для proxy сервера получать внешние IP:
![[Pasted image 20260406121204.png]]