-
Notifications
You must be signed in to change notification settings - Fork 63
/
Copy pathxtoph-deploy.yml
103 lines (75 loc) · 2.15 KB
/
xtoph-deploy.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
##
## First, need to set up the deployhost with
## needed software, services and settings
##
- hosts: myDeployhost
roles:
- role: xtoph_deploy
vars:
xtoph_deploy_action: "setup"
when: xtoph_deploy_cmd == "setup" or
xtoph_deploy_cmd == "setup+"
##
## Next, execute undeploy activities
##
## NOTE: hosts may (or may not) exist,
## majority of tasks run as 'delegate_to'
## and so we don't gather_facts
##
- hosts: myBastion,myNodes
gather_facts: no
roles:
- role: xtoph_deploy
vars:
xtoph_deploy_action: "undeploy"
when: xtoph_deploy_cmd == "undeploy" or
xtoph_deploy_cmd == "redeploy"
##
## Before we start deploying systems, we
## need to ensure certain basics are configured.
## Run the 'deploy_preprocess' to:
## - generate MAC addresses if needed
## - add DNS entries to /etc/hosts
## - maybe more stuff, go look!
##
- hosts: myBastion,myNodes
gather_facts: no
roles:
- role: xtoph_deploy
vars:
xtoph_deploy_action: "preprocess"
when: xtoph_deploy_cmd == "deploy" or
xtoph_deploy_cmd == "setup+" or
xtoph_deploy_cmd == "redeploy"
##
## For the RHEL 8 Workshop, there are
## no concurrency issues, so proceed
## to deploy everything at once
##
## NOTE: for same reasons listed above
## don't gather_facts
##
## NOTE: 'serial: #' limits concurrent
## deployments and resolves problems
## related to disk space and i/o
## limits
##
- hosts: myBastion,myNodes
gather_facts: no
serial: 3
roles:
- role: xtoph_deploy
vars:
xtoph_deploy_action: "deploy"
when: xtoph_deploy_cmd == "deploy" or
xtoph_deploy_cmd == "setup+" or
xtoph_deploy_cmd == "redeploy"
##
## All nodes should be deployed
## So proceed to configure the workshop
##
- import_playbook: playbooks/rhel8-workshop.yml
when: xtoph_deploy_cmd == "deploy" or
xtoph_deploy_cmd == "setup+" or
xtoph_deploy_cmd == "redeploy" or
xtoph_deploy_cmd == "workshop"