postgresql_cluster
postgresql_cluster copied to clipboard
Patroni pre-checks: check etcd cluster accessible
I suggest checking the network availability of the etcd cluster before adding nodes to the Patroni cluster. If etcd is unavailable for some reason, don't even attempt to add the node.
I created the role patroni/pre-checks for this purpose and added it to the playbooks deploy_pgcluster.yml and add_pgnode.yml.
I considered adding this checks to other playbooks but decided it might hinder the administrator from updating the cluster in some situations, which could be unsafe.
@lavr Thanks!
Maybe it 's worth move this task to an already existing pre-checks role?
- https://github.com/vitabaks/postgresql_cluster/tree/master/roles/pre-checks/tasks