feat(proxy): add consul agents to proxies and register haproxy service to consul is consul is enabled
This commit is contained in:
parent
267a23317f
commit
5204358a20
3
docs/consul_clusters.md
Normal file
3
docs/consul_clusters.md
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
# Deploying a Consul cluster
|
||||||
|
|
||||||
|
This documentation explains each steps necessary to successfully deploy a Consul cluster using the ednz_cloud.hashistack ansible collection.
|
@ -55,6 +55,7 @@ vault_service_registration_configuration:
|
|||||||
consul:
|
consul:
|
||||||
address: "127.0.0.1:8500"
|
address: "127.0.0.1:8500"
|
||||||
scheme: "http"
|
scheme: "http"
|
||||||
|
token: ""
|
||||||
|
|
||||||
#########
|
#########
|
||||||
# plugins
|
# plugins
|
||||||
|
@ -7,3 +7,14 @@
|
|||||||
- name: "Include ednz_cloud.deploy_keepalived"
|
- name: "Include ednz_cloud.deploy_keepalived"
|
||||||
ansible.builtin.include_role:
|
ansible.builtin.include_role:
|
||||||
name: ednz_cloud.deploy_keepalived
|
name: ednz_cloud.deploy_keepalived
|
||||||
|
|
||||||
|
- name: "Register haproxy services in consul"
|
||||||
|
when: enable_consul | bool
|
||||||
|
block:
|
||||||
|
- name: "Register haproxy services in consul"
|
||||||
|
community.general.consul:
|
||||||
|
token: "{{ _consul_cluster_config.root_token.secret_id }}"
|
||||||
|
service_name: haproxy
|
||||||
|
service_port: 80
|
||||||
|
interval: 20s
|
||||||
|
http: http://localhost:9000/health
|
||||||
|
Loading…
Reference in New Issue
Block a user