From 109c6b750751d1c5cd216ad2f09258cf512c4c9e Mon Sep 17 00:00:00 2001 From: Larry Smith Jr Date: Sat, 3 Dec 2016 17:51:25 -0500 Subject: Addressed issue #6 Signed-off-by: Larry Smith Jr --- Vagrant/roles/ansible-rabbitmq/playbook.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 Vagrant/roles/ansible-rabbitmq/playbook.yml (limited to 'Vagrant/roles/ansible-rabbitmq/playbook.yml') diff --git a/Vagrant/roles/ansible-rabbitmq/playbook.yml b/Vagrant/roles/ansible-rabbitmq/playbook.yml new file mode 100644 index 0000000..498c829 --- /dev/null +++ b/Vagrant/roles/ansible-rabbitmq/playbook.yml @@ -0,0 +1,25 @@ +--- +- hosts: all + become: true + vars: + - pri_domain_name: 'test.vagrant.local' + roles: + tasks: + - name: updating /etc/hosts + lineinfile: + dest: /etc/hosts + regexp: "^{{ hostvars[item].ansible_ssh_host }} {{ item }} {{ item }}.{{ pri_domain_name }}" + line: "{{ hostvars[item].ansible_ssh_host }} {{ item }} {{ item }}.{{ pri_domain_name }}" + state: present + with_items: groups['all'] + +- hosts: all + become: true + vars: + - rabbitmq_config_ha: true + - rabbitmq_enable_clustering: true + - pri_domain_name: 'test.vagrant.local' + - rabbitmq_master: 'node0' + roles: + - role: ansible-rabbitmq + tasks: -- cgit v1.2.3