Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upPrometheus 2.2.0-rc.1 alerts does not support advanced yaml anchor syntax #3889
Comments
This comment has been minimized.
This comment has been minimized.
|
If you want to template files then using the templating feature of your configuration management system. This is expected behaviour, unknown fields cause an error to warn about typos and in general I would recommend avoiding the YAML anchor features. |
brian-brazil
closed this
Mar 3, 2018
This comment has been minimized.
This comment has been minimized.
lock
bot
commented
Mar 22, 2019
|
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
lock
bot
locked and limited conversation to collaborators
Mar 22, 2019
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
freznicek commentedFeb 26, 2018
What did you do?
I failed to use advanced yaml anchor syntax in prometheus alert definition.
Why I want that? I want to reduce alert definition duplications.
This prometheus alert rule yaml fails to parse due to strict field existence rules:
Promtool alert checker says:
What did you expect to see?
I'd like to see prometheus supporting
<<: *syntax.Moreover Prometheus should define which fields are ignored, for instance the way as gitlab-ci.yml does (ignores everything strating with dot).
What did you see instead? Under which circumstances?
Above alert not valid:
Environment
System information:
multiple specs:
Linux 4.6.0-0.bpo.1-amd64 x86_64
Linux 4.11.12-100.fc24.x86_64 x86_64
Prometheus version:
Prometheus configuration file:
Sorry cannot disclose this at this point.
Logs: