How to get graylog running behind a proxy?

(Amit Sharma) #1

I need to host my Graylog URL using proxy server i.e haproxy

i am trying to use Private_IP:9000 in haproxy

backend graylog_cluster
mode http
option http-keep-alive
balance roundrobin
option forwardfor
cookie JSESSIONID prefix

    server graylog01 Private-IP:9000 cookie A check

I am able to telnet the from my proxy server ( haproxy )

Please help !!

(Amit Sharma) #2

No worry, issue has been resolved now :slight_smile:

(Jan Doberstein) #3

it would be pleaseful if you would share with the community how you have solved your issue and what had helped you!


(Amit Sharma) #4

sure @jan :slight_smile: I did the following thingsā€¦
frontend http

option forwardfor
http-request add-header X-Forwarded-Host %[req.hdr(host)]
http-request add-header X-Forwarded-Server %[req.hdr(host)]
http-request add-header X-Forwarded-Port %[dst_port]
acl is_graylog hdr_dom(host) -i -m str graylog_url_domain
use_backend     graylog if is_graylog

backend graylog
description The Graylog Web backend.
http-request set-header X-Graylog-Server-URL https://graylog_url_domain/api
use-server graylog_1
server graylog_1 Private_IP:9000 maxconn 20 check

I got these details in graylog doc.

I used lets-encrypt to enable ssl

(system) closed #5

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.