Hi, this is not a bug, but a feature request.
Instead of manually providing nginx.conf file. Is it possible to add native proxy protocol support in Kong?
@shamil, do you mean to provide a configuration variable for that?
@bungle, yes. A configuration option
@shamil, the small problem I see here is that proxy protocol is exclusive (correct me if I'm wrong), and if you still want to support non-proxy protocol that practically means two different server blocks (?). What do you think?
@bungle yes, it's exclusive.
Having another port just for proxy_protocol is good idea, but IMHO it's nice to have, not must. But at least kong should have a possibility to let users enable proxy_protocol for all APIs
In my opinion in most cases when you want proxy_protocol, in those cases kong proxy usually sits behind load-balancer like ELB or Haproxy, so you will want it for all APIs.
@bungle what you think? Is it reasonable?
Also real_ip_header should be set to proxy_protocol, so the real IP can be retrieved properly, which I think is already beeing addresed here: https://github.com/Mashape/kong/pull/2236
@shamil I think it is reasonable and it is easy to implement. Yes, I was thinking the same that if real_ip_header is set to proxy_protocol we could just generate the associated listen directives, and that's it.
@shamil, if you have time to test #2236 for Proxy protocol functionality and give us feedback, that would be greatly appreciated!
@bungle thanks, as soon as I get back from vacation (Thursday) I will run tests and report
@bungle tested, works as expected. Setting real_ip_header to proxy_protocol will update the listen directive accordingly.
And my Load-balancer was able to successfully communicate with kong using proxy_protocol
Thanks a lot...
Most helpful comment
@shamil I think it is reasonable and it is easy to implement. Yes, I was thinking the same that if
real_ip_headeris set toproxy_protocolwe could just generate the associated listen directives, and that's it.