-
Notifications
You must be signed in to change notification settings - Fork 0
/
130.3_Playbook_create_dd_mtree_with_nfs.yml
53 lines (48 loc) · 1.48 KB
/
130.3_Playbook_create_dd_mtree_with_nfs.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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Example Playbok to configure PPDD
- name: Playbook to configure DataDomain for PPDM
hosts: localhost
gather_facts: no
connection: local
vars_files:
- ./vars/main.yml
tasks:
- name: Checking if PPDD FQDN / IP is set
fail:
msg: "We do not have ppdd fqdn set !"
when: (ppdd_fqdn is not defined) or (ppdd_fqdn|length <= 8)
- name: Checking PPDD_PASSWORD is set
fail:
msg: "We do not have ppdd_password set !"
when: (ppdd_password is not defined) or (ppdd_password|length == 0)
- name: Setting Base URL
set_fact:
ppdd_baseurl: "{{ ppdd_fqdn }}"
- name: Check DataDomain Appliance Ready {{ ppdd_fqdn }}
include_role:
name: wait_ppdd_api_ready
- debug:
msg: "{{ result }}"
verbosity: 1
- name: Get PPDD Token for {{ ppdd_fqdn }}
vars:
username: "{{ ppdd_username }}"
password: "{{ ppdd_password }}"
include_role:
name: get_ppdd_token
- debug:
msg: "{{ access_token }}"
verbosity: 1
- name: Ensure mtree for PPDM nfs Export
include_role:
name: set_ppdd_mtree
vars:
mtree_name: "{{ new_mtree }}"
- name: Ensure PPDM nfs Export
include_role:
name: set_ppdd_nfs_export
vars:
export_name: "{{ mtree_name | basename}}"
export_path: "{{ mtree_name }}"
clients:
client_name: "{{ ppdd_nfs_hosts | split(',') }}"
client_options: sec=sys,rw,no_root_squash,no_all_squash,secure,version=4