autometrics-dev / am

Autometrics Companion CLI app
Apache License 2.0
16 stars 2 forks source link

Ensure that the correct listen address is passed along to prometheus/pushgateway #100

Closed hatchan closed 1 year ago

hatchan commented 1 year ago

Currently we have the web external address hardcoded for the prometheus/pushgateway: https://github.com/autometrics-dev/am/blob/198153538406163f4f0af95644135145472156c4/src/bin/am/commands/start.rs#L600

This needs to follow what the user has specified as their listen address. NOTE: it is possible that the user uses 0.0.0.0 as the ip or that they use :0 as the port. In these cases we need to figure out what the values should be (ie. using a :0 port means that a random unused port will be used when the socket is opened).