Skip to content

Commit cf76c63

Browse files
committed
fix: explicit 127.0.0.1 proxy and trust IPv6 loopback in Gotify
1 parent 11bb8b4 commit cf76c63

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ ENV WORKDIR=/app \
1717
# Gotify settings
1818
GOTIFY_SERVER_PORT=8080 \
1919
# Trust Caddy proxy (localhost) to correctly parse X-Forwarded-For
20-
GOTIFY_SERVER_TRUSTEDPROXIES='["127.0.0.1"]'
20+
GOTIFY_SERVER_TRUSTEDPROXIES='["127.0.0.1", "::1"]'
2121

2222
WORKDIR $WORKDIR
2323

config/Caddyfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
}
6262

6363
# Proxy to the application backend
64-
reverse_proxy localhost:8080 {
64+
reverse_proxy 127.0.0.1:8080 {
6565
header_up X-Real-IP {http.request.header.CF-Connecting-IP:{http.request.header.Fly-Client-IP:{remote_host}}}
6666
header_up X-Forwarded-For {http.request.header.CF-Connecting-IP:{http.request.header.Fly-Client-IP:{remote_host}}}
6767
}

0 commit comments

Comments
 (0)