mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-11-26 11:51:02 +00:00
Update proxy documentation (#573)
This commit is contained in:
parent
4642d98f2e
commit
ca465cec1a
1 changed files with 3 additions and 50 deletions
|
@ -82,55 +82,8 @@ server {
|
||||||
This guide provides a brief overview for installing Woodpecker server behind the [Caddy webserver](https://caddyserver.com/). This is an example caddyfile proxy configuration:
|
This guide provides a brief overview for installing Woodpecker server behind the [Caddy webserver](https://caddyserver.com/). This is an example caddyfile proxy configuration:
|
||||||
|
|
||||||
```nohighlight
|
```nohighlight
|
||||||
woodpecker.mycompany.com {
|
woodpecker.example.com {
|
||||||
gzip {
|
reverse_proxy woodpecker-server:8000
|
||||||
not /stream/
|
|
||||||
}
|
|
||||||
proxy / localhost:8000 {
|
|
||||||
websocket
|
|
||||||
transparent
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
You must disable gzip compression for streamed data otherwise the live updates won't be instant:
|
|
||||||
|
|
||||||
```diff
|
|
||||||
woodpecker.mycompany.com {
|
|
||||||
+ gzip {
|
|
||||||
+ not /stream/
|
|
||||||
+ }
|
|
||||||
proxy / localhost:8000 {
|
|
||||||
websocket
|
|
||||||
transparent
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
You must configure the proxy to enable websocket upgrades:
|
|
||||||
|
|
||||||
```diff
|
|
||||||
woodpecker.mycompany.com {
|
|
||||||
gzip {
|
|
||||||
not /stream/
|
|
||||||
}
|
|
||||||
proxy / localhost:8000 {
|
|
||||||
+ websocket
|
|
||||||
transparent
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
You must configure the proxy to include `X-Forwarded` headers using the `transparent` directive:
|
|
||||||
|
|
||||||
```diff
|
|
||||||
woodpecker.mycompany.com {
|
|
||||||
gzip {
|
|
||||||
not /stream/
|
|
||||||
}
|
|
||||||
proxy / localhost:8000 {
|
|
||||||
websocket
|
|
||||||
+ transparent
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -138,7 +91,7 @@ woodpecker.mycompany.com {
|
||||||
After installing [ngrok](https://ngrok.com/), open a new console and run:
|
After installing [ngrok](https://ngrok.com/), open a new console and run:
|
||||||
|
|
||||||
```
|
```
|
||||||
ngrok http 80
|
ngrok http 8000
|
||||||
```
|
```
|
||||||
|
|
||||||
Set `WOODPECKER_HOST` (for example in `docker-compose.yml`) to the ngrok url (usually xxx.ngrok.io) and start the server.
|
Set `WOODPECKER_HOST` (for example in `docker-compose.yml`) to the ngrok url (usually xxx.ngrok.io) and start the server.
|
||||||
|
|
Loading…
Reference in a new issue