Graylog 6.0 browsing fails with nginx https reverse proxy and path prefix
Expected Behavior
Browsing the web UI should work fine.
Current Behavior
The links are: https://log.domain.tld/graylog/graylog/search https://log.domain.tld/graylog/graylog/streams
Which ends up with a "Page not found".
Possible Solution
Steps to Reproduce (for bugs)
- Login and try to browse the UI
Context
I'm trying to create a new setup with Graylog 6 behind nginx reverse proxy with a path prefix and https. This setup works for Graylog 5.2, but fails for Graylog 6.0.
The problem is that after login, the links are: https://log.domain.tld/graylog/graylog/search https://log.domain.tld/graylog/graylog/streams
Which ends up with a "Page not found".
server_name log.domain.tld;
location /graylog/ {
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Graylog-Server-URL https://$host/graylog/;
rewrite ^/graylog/(.*)$ /$1 break;
proxy_pass http://graylog:9000;
}
After removing the path prefix (serving directly from /) it works fine.
Your Environment
- Graylog Version: 6.0.0-rc.4-1
- Java Version: 17.0.11
- OpenSearch Version: 2.13.0
- MongoDB Version: 7.0.8
- Operating System: Linux Gentoo / Docker
- Browser version: Chromium 122.0.6261.128
Thanks for the report @hydrapolic! It looks like this is the same issue as https://github.com/Graylog2/graylog2-server/issues/18463.
Yes, thanks @thll, missed that one.
Duplicate of #18463