forked from lukeharvey/ansible-initial-server-setup
-
Notifications
You must be signed in to change notification settings - Fork 0
/
initial_server_setup-test-bootflags.yml
59 lines (57 loc) · 2.03 KB
/
initial_server_setup-test-bootflags.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
---
# https://stackoverflow.com/questions/18195142/safely-limiting-ansible-playbooks-to-a-single-machine
- hosts: "iot"
gather_facts: no
remote_user: "{{ ssh_user | default('ansible_adm') }}"
roles:
- role: munin_server
when: inventory_hostname == 'iot'
# - hosts: "{{ target | default('all,!openwrt,!tasmota') }}"
# remote_user: "{{ ssh_user | default('ansible_adm') }}"
# gather_facts: no
# vars_files:
# - vars/main.yml
# roles:
# - role: common_handlers
# become: true # the whole role, including handlers, will become root
# - install_files
# - install_user_files
- hosts: "{{ target | default('all,!openwrt,!tasmota') }}"
remote_user: "{{ ssh_user | default('ansible_adm') }}"
# gather_facts: no # when doing a very quick debug run
vars_files:
- vars/main.yml
roles:
- role: common_handlers
become: true # the whole role, including handlers, will become root
# - role: bootstrap
# - role: ssh_bootstrap
# become: true
# - role: management
# when: host_is_mgmt | default(false)
# - user
# - essentials
# - monitoring
- role: spectre_mitigations_disabled
when: not (host_is_container | default(false)) and not (host_is_pi | default(false))
# pve_server is loaded in bootstrap.yml as well, but that's just to make sure all the repos are there. No harm updating that here as time goes on
# - role: hostname
# when: not (host_is_container | default(false))
# - role: fileserver
# when: host_is_fileserver | default(false)
# - role: mailserver
# when: host_is_mailserver | default(false)
- role: pve_server
when: host_is_pve_server | default(false)
# - role: virtual
# when: host_is_virtual | default(false)
# - role: physical
# when: host_is_physical | default(false)
# - role: laptop
# when: host_is_laptop | default(false)
# - role: dell_server
# when: host_is_dell_server | default(false)
# - role: desktop
# when: host_is_desktop | default(false)
# - role: ssh
# - role: fail2ban