-
Notifications
You must be signed in to change notification settings - Fork 22
/
provision.yml
180 lines (163 loc) · 4.96 KB
/
provision.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
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
---
- hosts: all
gather_facts: no
tasks:
- name: Read vars from secrets file
include_vars: "{{ secrets_file }}"
no_log: true
tags:
- always
- hosts: base
gather_facts: yes
become: true
roles:
- role: common
tags: ['core', 'base', 'common']
- role: rsyslog
tags: ['core', 'base', 'rsyslog']
- role: iptables
when:
- iptables_enable | bool
tags: ['core', 'base', 'iptables']
- role: selfsigned_certs
when:
- use_selfsigned_certs
tags: ['core', 'base', 'selfsigned_certs']
- hosts: frontend
become: true
roles:
- role: hosts
when:
- update_hosts_file
tags: ['core', 'frontend', 'hosts']
- role: httpd
tags: ['core', 'frontend', 'httpd']
- role: welcome
when:
- use_welcome_role
tags: ['core', 'frontend', 'welcome']
- hosts: loadbalancer
gather_facts: true
become: true
roles:
- role: haproxy
tags: ['core', 'loadbalancer', 'lb']
- role: keepalived
when:
- inventory_hostname in groups['loadbalancer_ha']
tags: ['core', 'loadbalancer', 'keepalived']
- role: bind
when:
- inventory_hostname in groups['loadbalancer_ha']
tags: ['core', 'loadbalancer', 'bind']
- hosts: db_mysql
gather_facts: no
become: true
roles:
- role: mysql
when:
- inventory_hostname in groups['storage']
tags: ['core', 'db_mysql', 'mysql']
- role: galera
when:
- inventory_hostname in groups['dbcluster']
tags: ['core', 'db_mysql', 'galera']
- role: keepalived
when:
- inventory_hostname in groups['dbcluster_nodes']
tags: ['core', 'db_mysql', 'keepalived']
- role: galera_create_users
when:
- inventory_hostname in groups['dbcluster']
tags: ['core', 'db_mysql', 'galera', 'galera_create_users']
- hosts: mongo_servers
gather_facts: yes
become: true
roles:
- role: mongo
tags: ['core', 'mongo']
- hosts: app_java
gather_facts: true
become: true
roles:
- role: java
tags: ['core', 'app_java', 'java']
- role: shibboleth
tags: ['core', 'app_java', 'shib']
handlers:
- import_tasks: roles/httpd/handlers/main.yml
# run -t springboot -e springboot_service_to_deploy=manage,voot to only install
# the manage and voot app. Both GUI as servers will be installed.
- hosts: java_apps
become: true
roles:
- { role: springboot, tags: ['core', 'springboot'] }
handlers:
- import_tasks: roles/httpd/handlers/main.yml
- hosts: app_php
gather_facts: no
become: true
roles:
- role: profile
when:
- inventory_hostname not in groups['lifecycle']
tags: ['core', 'app_php', 'profile']
handlers:
- import_tasks: roles/httpd/handlers/main.yml
- hosts: elk
gather_facts: true
become: true
roles:
- role: elk
tags: ['elk' ]
- hosts: stats
gather_facts: true
become: true
roles:
- role: influxdb
tags: ['influxdb' ]
handlers:
- include_tasks: roles/httpd/handlers/main.yml
- hosts: stepuppapp
become: true
roles:
- { role: stepupwebauthn, tags: ['stepupwebauthn','stepup' ] }
- { role: stepupazuremfa, tags: ['stepupazuremfa', 'stepup'] }
- { role: stepupmiddleware, tags: ['stepupmiddleware' , 'stepup'] }
- { role: stepupgateway, tags: ['stepupgateway' , 'stepup'] }
- { role: stepupselfservice, tags: ['stepupselfservice' , 'stepup'] }
- { role: stepupra , tags: ['stepupra' , 'stepup'] }
- { role: stepupgateway , tags: ['stepupgateway' , 'stepup'] }
- hosts: docker_apps1,docker_apps2
become: true
roles:
- { role: docker, tags: ['docker' ] }
- hosts: docker_apps1
become: true
roles:
- { role: invite, tags: ['invite' ] }
- { role: dashboard, tags: ["dashboard"] }
- { role: teams, tags: ["teams"] }
- { role: pdp, tags: ["pdp"] }
- { role: voot, tags: ["voot"] }
- { role: attribute-aggregation, tags: ["aa", "attribute-aggregation"] }
- { role: mujina-idp, tags: ["mujina-idp"] }
- { role: oidc-playground, tags: ["oidc-playground"] }
- { role: myconext, tags: ["myconext"] }
- { role: manage, tags: ["manage"] }
- { role: oidcng, tags: ["oidcng"] }
- { role: stats, tags: ["stats"] }
- { role: diyidp, tags: ["diyidp"] }
- { role: profile, tags: ["profile"] }
- { role: lifecycle, tags: ["lifecycle"] }
- { role: stepuptiqr, tags: ['stepuptiqr' , 'stepup'] }
- hosts: docker_apps2
become: true
roles:
- { role: engineblock, tags: ["eb"] }
- hosts: docker_mariadb
become: true
roles:
- { role: mariadbdocker, tags: ['mariadbdocker']}
- { role: mongodbdocker, tags: ['mongodbdocker']}
- import_playbook: "{{ environment_dir }}/playbook.yml"