-
Notifications
You must be signed in to change notification settings - Fork 15
/
tower_node_setup.yml
55 lines (47 loc) · 1.09 KB
/
tower_node_setup.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
---
- name: Setup Tower cluster nodes
hosts: all
tasks:
- name: Add the http/d firewall services
firewalld:
service: "{{ item }}"
immediate: true
permanent: true
state: enabled
with_items:
- http
- https
- name: Add the rabbitmq firewall ports
firewalld:
port: "{{ item }}/tcp"
immediate: true
permanent: true
state: enabled
with_items:
- 4369
- 25672
- 15672
- name: Partition the second disk
parted:
device: /dev/vdb
number: 1
state: present
- name: Format the second disk as xfs
filesystem:
fstype: xfs
dev: /dev/vdb1
- name: Mount the second disk under /var/lib/awx
mount:
path: /var/lib/awx
src: /dev/vdb1
fstype: xfs
state: present
- name: Enable the ansible repository
shell:
cmd: subscription-manager repos --enable=rhel-7-server-ansible-2-rpms
register: result
- name: install ansible
yum:
name: ansible
state: latest
when: result is success