mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-21 09:35:49 +02:00
Add documentation on how to put Part-DB into a subpath of a reverse proxy
This fixes issue #428
This commit is contained in:
parent
93d0f97cfd
commit
5f86253b94
1 changed files with 18 additions and 1 deletions
|
@ -21,3 +21,20 @@ TRUSTED_PROXIES=192.168.2.10
|
||||||
|
|
||||||
Set the `DEFAULT_URI` environment variable to the URL of your Part-DB installation, available from the outside (so via
|
Set the `DEFAULT_URI` environment variable to the URL of your Part-DB installation, available from the outside (so via
|
||||||
the reverse proxy).
|
the reverse proxy).
|
||||||
|
|
||||||
|
## Part-DB in a subpath via reverse proxy
|
||||||
|
|
||||||
|
If you put Part-DB into a subpath via the reverse proxy, you have to configure your webserver to include `X-Forwarded-Prefix` in the request headers.
|
||||||
|
For example if you put Part-DB behind a reverse proxy with the URL `https://example.com/partdb`, you have to set the `X-Forwarded-Prefix` header to `/partdb`.
|
||||||
|
|
||||||
|
In apache, you can do this by adding the following line to your virtual host configuration:
|
||||||
|
|
||||||
|
```
|
||||||
|
RequestHeader set X-Forwarded-Prefix "/partdb"
|
||||||
|
```
|
||||||
|
|
||||||
|
and in nginx, you can do this by adding the following line to your server configuration:
|
||||||
|
|
||||||
|
```
|
||||||
|
proxy_set_header X-Forwarded-Prefix "/partdb";
|
||||||
|
```
|
Loading…
Add table
Add a link
Reference in a new issue