Feature request: respect http_proxy env variable while connecting to M/Monit collector

Issue #212 closed
Tomasz Loszko created an issue

If there is proxy (like squid proxy) between Monit and M/Monit, it is not possible to report data to collector.

Cannot create socket to [xxx]:xxxx -- Network is unreachable
M/Monit: cannot open a connection to http://[xxx]:xxxx/collector

Socket should be opened to the proxy server (provided in config file? or taken from env variable) and 'CONNECT' message with target host should be sent~

Comments (1)

  1. Tildeslash repo owner

    Both M/Monit and Monit can be used behind a reverse HTTP proxy, but as you surmised the HTTP CONNECT method is not supported. It is doubtful if it will be as this is the first and only request for this. Some workarounds exist however, such as setting up Apache as a reverse proxy in front of M/Monit and have this communicate with Squid. A plain old SSH-tunnel might also be an option?

  2. Log in to comment