graylog 3.0之前的版本在反向代理中存在bug,3.0版本已经修复
具体参考: https://github.com/Graylog2/graylog2-server/issues/5702 Graylog 3.0.1 released on April 1st, 2019 fixes this issue: Fix running Graylog web interface under a path prefix. Graylog2/graylog2-server#5702 Graylog2/graylog2-server#5703 In addition, new version fixes these other [issues](http://docs.graylog.org/en/3.0/pages/changelog.html). graylog版本日志以及修改的问题:http://docs.graylog.org/en/3.0/pages/changelog.html
不管是通过docker 安装,还是安装包 。配置基本上一样,只需要理解即可 ,下面为我截取的官网一些有帮助大家配置的截图,希望对大家有帮助
官网的教程:
http://docs.graylog.org/en/3.0/pages/configuration/web_interface.html#nginx
具体配置参考
NGINX的核心配置已经截图贴出来,具体参考上面。
下面为graylog 核心配置
How does the web interface connect to the Graylog server? The web interface is fetching all information it is showing from the REST API of the Graylog server. Therefore it needs to connect to it using HTTP(S). There are several ways how you can define which way the web interface connects to the Graylog server. The URI used by the web interface is determined in this exact order: If the HTTP(S) client going to the web interface port sends a X-Graylog-Server-URL header, which contains a valid URL, then this is overriding everything else. If http_external_uri is defined in the Graylog configuration file, this is used if the aforementioned header is not set. If http_publish_uri is defined in the Graylog configuration file, this is used if the aforementioned http_external_uri is not set. If none of the above are defined, http://$http_bind_address is used. The web interface assets (e.g. the index.html, CSS and JavaScript files) are accessible at the URI root (/ by default) and the REST API endpoints are accessible at the /api path. Example: Setting http_bind_address to 10.0.0.1:9000 configures the Graylog server with the following URLs. Web interface: http://10.0.0.1:9000/ REST API: http://10.0.0.1:9000/api/
http_external_uri 这个你就理解为他可以通过此uri配置web interface 资源路径
[参考文档]
http://docs.graylog.org/en/2.4/pages/configuration/web_interface.html#configuring-webif
http://docs.graylog.org/en/3.0/pages/configuration/web_interface.html#nginx
https://github.com/Graylog2/graylog2-server/issues/5702