ansible-collections / ansible-consul

:satellite: Ansible role for Hashicorp Consul clusters
https://galaxy.ansible.com/ansible-community/consul/
BSD 2-Clause "Simplified" License
450 stars 313 forks source link

feat: Configuration validation. fix #518 #592

Closed bastienwirtz closed 6 months ago

bastienwirtz commented 6 months ago
SUMMARY

Following discussion on https://github.com/ansible-collections/ansible-consul/pull/565, this patch implement the validation during install / update only

ISSUE TYPE

Feature Pull Request

COMPONENT NAME

config tasks

ADDITIONAL INFORMATION

All configuration files must be given to the validate command at once (partial conf might raise some issue regarding missing some required items), so it's not possible to use the validate arg og the ansibvle.builtin.copy module used to template the config (cc @rndmh3ro).

rndmh3ro commented 6 months ago

LGTM!

It'd be nice if you could add your rationale to the task itself so people who read the code will get an understanding why it is the way it is.

bastienwirtz commented 6 months ago

@rndmh3ro @nre-ableton Updated !