Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request for dry-run feature #111

Open
k0ste opened this issue Aug 9, 2022 · 0 comments
Open

Request for dry-run feature #111

k0ste opened this issue Aug 9, 2022 · 0 comments

Comments

@k0ste
Copy link

k0ste commented Aug 9, 2022

With dry-run feature we will can to put ssl_exporter configuration and perform syntax test (exporter can run with this YAML) before restart with new configuration (useful for IaC's)

For example, this YAML seems legit

---
- modules:
    https:
      prober: https

But

[root@mon ssl_exporter]# ./ssl_exporter --log.level=debug --web.listen-address=":9222" --config.file=ssl.yml
ts=2022-08-09T12:07:29.167Z caller=ssl_exporter.go:142 level=error msg="error parsing config file: yaml: unmarshal errors:\n  line 2: cannot unmarshal !!seq into config.Config"
[root@mon ssl_exporter]# echo $?
1

Will be nice if we can check it, like ./ssl_exporter --config.file=/path/to/file.yaml --dry-run and check for non-zero exit-code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant