Added keepalived definition and health_check script for rabbiteMQ
Change-Id: I6d6d4dde40041836c9284e19e833b0b2f63d5cf6
Related-Prod: PROD-32458
diff --git a/keepalived/cluster/instance/rabbitmq_vip.yml b/keepalived/cluster/instance/rabbitmq_vip.yml
new file mode 100644
index 0000000..922afc7
--- /dev/null
+++ b/keepalived/cluster/instance/rabbitmq_vip.yml
@@ -0,0 +1,16 @@
+classes:
+- service.keepalived.cluster.single
+parameters:
+ _param:
+ keepalived_rabbitemq_vrrp_script_content: 'rabbitmqctl cluster_status --formatter=erlang | grep -q "running_nodes.*$(hostname)"'
+ keepalived:
+ cluster:
+ vrrp_scripts:
+ rabbitemq_vip:
+ content: ${_param:keepalived_rabbitemq_vrrp_script_content}
+ interval: 10
+ rise: 1
+ fall: 1
+ instance:
+ VIP:
+ track_script: rabbitemq_vip