-
Notifications
You must be signed in to change notification settings - Fork 0
/
Testpoint-MaDDashbuild.yml
120 lines (100 loc) · 3.39 KB
/
Testpoint-MaDDashbuild.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
---
- hosts: [md-arch]
gather_facts: true
become: yes
tasks:
- name: For maddash VM, add epel and ps Repo
yum:
name:
- epel-release
- http://software.internet2.edu/rpms/el7/x86_64/latest/packages/perfsonar-repo-0.11-1.noarch.rpm
state: latest
- name: For maddash VM, add maddash and archive rpms to MaDDash Server
yum:
name:
- perfsonar-archive
- perfsonar-psconfig-publisher
- maddash
state: present
- name: Allow all IPs on net to access archiver's opensearch tool
ansible.builtin.lineinfile:
path: /etc/httpd/conf.d/apache-logstash.conf
regexp: '^(\s*# Require ip 10\.1\.1\.0/24)$'
line: 'Require ip 192.168.0.0/23'
backrefs: yes
- name: Start FW service if not running
service:
name: firewalld
state: started
- name: Enable FW service
service:
name: firewalld
enabled: yes
- name: Add http to firewall
firewalld:
service: http
permanent: yes
immediate: yes
state: enabled
- name: Add https to firewall
firewalld:
service: https
permanent: yes
immediate: yes
state: enabled
- name: Copy mesh.json file to Maddash node from Vagrant host
copy:
src: ./mesh.json
dest: /home/vagrant/mesh.json
owner: vagrant
group: vagrant
- name: Publish mesh.json file
command: "psconfig publish /home/vagrant/mesh.json"
- name: Remote add file, lets the archive know where the JSON config file lives
command: 'psconfig remote add "https://192.168.1.214/psconfig/mesh.json"'
- name: Add new project name for web site
ansible.builtin.replace:
path: /etc/maddash/maddash-webui/config.json
regexp: '"My perfSONAR Dashboard"'
replace: '"ps-v5"'
- name: Add correct grid name, so it opens first
ansible.builtin.replace:
path: /etc/maddash/maddash-webui/config.json
regexp: '"My Sites"'
replace: '"ps-v5-grid"'
- name: Restart psconfig-maddash-agent
service:
name: psconfig-maddash-agent
state: restarted
- name: Restart httpd
service:
name: httpd
state: restarted
- name: Shorten test times, packet loss, every 5min
command: "psconfig maddash-grid edit --name default_loss --check-interval PT5M"
- name: Shorten test time, throughput, every 2hr
command: "psconfig maddash-grid edit --name default_throughput --check-interval PT2H"
- hosts: [testpoint]
gather_facts: true
become: yes
tasks:
- name: Add perfsonar rpms for epel and ps Repo
yum:
name:
- epel-release
- http://software.internet2.edu/rpms/el7/x86_64/latest/packages/perfsonar-repo-0.11-1.noarch.rpm
state: latest
- name: Add perfsonar rpms to all testpoint edge nodes
yum:
name:
- perfsonar-testpoint
- perfsonar-toolkit-ntp
- perfsonar-toolkit-security
- perfsonar-toolkit-servicewatcher
state: present
- name: For testpoint VMs, install remote URL and archives
command: 'psconfig remote add "https://192.168.1.214/psconfig/mesh.json"'
- name: For testpoint VMs, restart psconfig-pscheduler-agent
service:
name: psconfig-pscheduler-agent
state: restarted