forked from IBM/ibm-spectrum-scale-install-infra
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathset_json_variables.yml
36 lines (32 loc) · 1.49 KB
/
set_json_variables.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
---
#- name: Create the required groups
- hosts: localhost
connection: local
tasks:
- name: Read all intermediate output from Resource Details
include_vars:
file: vars/scale_clusterdefinition.json
register: scale_json
- name: Check valid json file
assert:
that: scale_json.failed == false
msg: >-
scale_clusterdefinition.json is not present in the
vars directory. Make sure that this file is present
in the vars directory along with all required
Ansible scale inventory.
- name: Pass all inputs related to creating Spectrum Scale cluster to all nodes
add_host:
name: "{{ item.fqdn }}"
groups: scale_node
scale_storage: "{{ scale_storage | default(omit) }}"
scale_cluster_quorum: "{{ item.is_quorum_node | default(false) }}"
scale_cluster_manager: "{{ item.is_manager_node | default(false) }}"
scale_cluster_gui: "{{ item.is_gui_server | default(false) }}"
scale_zimon_collector: "{{ item.is_collector_node | default(false) }}"
state: "{{ item.state | default('present') }}"
ansible_ssh_private_key_file: "{{ item.ansible_ssh_private_key_file | default(omit) }}"
scale_cluster_clustername: "{{ scale_cluster.scale_cluster_name | default('gpfs1.local') }}"
scale_cluster_profile_name: "{{ scale_cluster.scale_cluster_profile_name | default(omit) }}"
scale_cluster_profile_dir_path: "{{ scale_cluster.scale_cluster_profile_dir_path | default(omit) }}"
loop: "{{ node_details }}"