Remove positional arguments and replace them with flags
znerol opened this issue · 0 comments
znerol commented
Currently prometheus node exporter accepts the following positional arguments:
positional arguments:
config Path to configuration file (pve.yml)
port Port on which the exporter is listening (9221)
address Address to which the exporter will bind
Initially pve_exporter
had no command line flags at all and positional arguments were the only way to customize the runtime behavior. In the meantime, support for command line flags and environment variables were added. It became possible to run pve_exporter
without a config file. Since none of those positional arguments are required, they should be converted into command line flags.
SNMP exporter uses the following flags:
--config.file="/etc/prometheus/snmp.yml"
Path to configuration file.
[...]
--web.listen-address=:9116 ...
Addresses on which to expose metrics and web interface. Repeatable for multiple addresses.