Closed 123BLiN closed 7 years ago
Hi @123BLiN
You can call .Checks.AggregatedStatus()
which should return "maintenance" for your maintenance-enabled services. It will also return "passing", "warning", etc where appropriate.
Please let me know if you have any questions.
Hi @sethvargo !
Could you please provide an example template? I'm having hard time to get it work.
update:
Sorry - my fault - it works with new consul-template version (0.19.3)
{{ .Checks.AggregatedStatus }}
Consul Template version
consul-template v0.18.2 (ecb9e46)
Configuration
Command
Debug output
Expected behavior
We are going to have 1000-2000 nginx configs and consul services, every CT makes 3 calls - we have faced ephemeral port exhaustion, we need a way to make only one call per template like so:
Unfortunately "maintenance" state is only accessible with filters but not with .Status property (it is still "passing")
It will be great if it will be accessible as a node's attribute, at least as an additional bool like .Maintenance = true/false if it is not possible to attach it to the .Status
What do you think?