Skip to content

Commit ab7e903

Browse files
committed
Create block for tasks.
1 parent bde16cd commit ab7e903

File tree

1 file changed

+17
-19
lines changed

1 file changed

+17
-19
lines changed

multinode-app.yml

Lines changed: 17 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -25,23 +25,21 @@
2525

2626
- hosts: localhost
2727
tasks:
28-
# Install the ansible requirements
29-
- name: Install ansible requirements
30-
command: ansible-galaxy install -r ansible/requirements.yml
31-
when: cluster_state != "absent"
32-
33-
# Import the playbook to start configuring the multi-node hosts.
34-
- name: Configure hosts and deploy ansible
35-
import_playbook: ansible/configure-hosts.yml
36-
when: cluster_state != "absent"
37-
38-
- debug: var=outputs
39-
vars:
40-
outputs:
41-
cluster_access_ip: "{{ hostvars[groups['openstack'][0]].cluster_gateway_ip }}"
42-
when: cluster_state != "absent"
43-
44-
- name: Show Playbook Directory
45-
debug:
46-
msg: "{{ playbook_dir }}"
28+
- block:
29+
# Install the ansible requirements
30+
- name: Install ansible requirements
31+
command: ansible-galaxy install -r ansible/requirements.yml
32+
33+
# Import the playbook to start configuring the multi-node hosts.
34+
- name: Configure hosts and deploy ansible
35+
import_playbook: ansible/configure-hosts.yml
36+
37+
- debug: var=outputs
38+
vars:
39+
outputs:
40+
cluster_access_ip: "{{ hostvars[groups['openstack'][0]].cluster_gateway_ip }}"
41+
42+
- name: Show Playbook Directory
43+
debug:
44+
msg: "{{ playbook_dir }}"
4745
when: cluster_state != "absent"

0 commit comments

Comments
 (0)