fabiolb / fabio

Consul Load-Balancing made simple
https://fabiolb.net
MIT License
7.25k stars 619 forks source link

Unix socket support for registry.consul.addr? #773

Open dradtke opened 4 years ago

dradtke commented 4 years ago

My setup has most Consul communication happening over a Unix socket, and it looks like registry.consul.addr doesn't work when given a file path or a unix:// address. Is there a way to do this that I'm missing?

dradtke commented 4 years ago

To provide a little more context: I want to run Fabio on Nomad, which is already configured to talk to Consul with HTTPS over a Unix socket, and I want to be able to have Fabio reuse those settings.

pingiun commented 3 years ago

I think in the spirit of fabio being zero-config, it's important that fabio picks up the CONSUL_HTTP_ADDR environment variable when available. The consul api already does this when no address is provided in the config.

pingiun commented 3 years ago

I've found that the CONSUL_HTTP_ADDR environment variable is picked up when I run fabio with

args = ["-registry.consul.addr", ""]