prometheus-community / ipmi_exporter

Remote IPMI exporter for Prometheus
MIT License
473 stars 133 forks source link

TLS and --web-config-file #110

Closed reet- closed 2 years ago

reet- commented 2 years ago

Hi,

What am I doing wrong?

$ prometheus-ipmi_exporter --version
ipmi_exporter, version 1.5.1 (branch: HEAD, revision: a3d8f40c189245e0ee63aaebc8f90c137b6a5e55)
  build user:       root@42aadaf5c3c7
  build date:       20220221-21:42:56
  go version:       go1.17.7
  platform:         linux/amd64

$ /usr/local/bin/prometheus-ipmi_exporter --web.config.file=/opt/prometheus/tls_auth.yml
prometheus-ipmi_exporter: error: unknown long flag '--web.config.file', try --help

$ /usr/local/bin/prometheus-ipmi_exporter --help
usage: prometheus-ipmi_exporter [<flags>]

Flags:
  -h, --help                     Show context-sensitive help (also try --help-long and --help-man).
      --config.file=CONFIG.FILE  Path to configuration file.
      --freeipmi.path=FREEIPMI.PATH  
                                 Path to FreeIPMI executables (default: rely on $PATH).
      --web.listen-address=":9290"  
                                 Address to listen on for web interface and telemetry.
      --log.level=info           Only log messages with the given severity or above. One of: [debug, info, warn, error]
      --log.format=logfmt        Output format of log messages. One of: [logfmt, json]
      --version                  Show application version.

Thanks.

bitfehler commented 2 years ago

Well, that obviously depends on what exactly you are trying to do :slightly_smiling_face:

As the output you posted indicates, --web.config.file is not a valid flag. Given that your are passing a file, I assume you want --config.file.

Note that this flag expects an IPMI exporter config file, not a Prometheus config file. I am just guessing from the path you are using there that this might be a mixup.

reet- commented 2 years ago

I want to enable https scheme scraping with TLS auth, as described in the ipmi_exporter README (TLS and basic authentication). The parameter is specified as --web.config.file ...

bitfehler commented 2 years ago

I see. @SuperQ: you added that to the README, it does indeed not work, maybe you can take a look?

reet- commented 2 years ago

Oh, the TLS support commit is post 1.5.1. So it is described in the README, but not yet in the current downloadable release.

reet- commented 2 years ago

Works with ipmi_exporter compiled from source (5f7c5fe), closing.

SuperQ commented 2 years ago

Yea, we should probably cut a release soon.