-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathsagenv-sysprep-base.yaml
63 lines (57 loc) · 1.46 KB
/
sagenv-sysprep-base.yaml
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
---
- name: Load vars
hosts: "*"
vars:
default_var_files:
- "./vars/base_sysprep.yaml"
- "~/.custom_sysprep.yaml"
tasks:
- name: Build a list of all the files to load.
set_fact:
all_var_files: "{{ default_var_files + (include_var_files | default([]) ) }}"
- name: Print the var files to include
debug:
msg: "Var file to load in order: {{ all_var_files | join(',') }}"
- name: Include vars
include_vars:
file: "{{ item }}"
with_fileglob: "{{ all_var_files }}"
ignore_errors: yes
tags:
- always
- hosts: localhost
become: true
tasks:
- name: Non Root tasks
block:
## this is to make sure we gather the facts again as the user {{ cce_owner }} in order to get a valid {{ ansible_env.HOME }}
- setup:
- import_role:
name: create-known-hosts
become: false
tags:
- sysprep
- setup_ansible
- hosts: "{{ inventory_groupnames }}"
become: true
tasks:
- import_role:
name: manage-packages
- name: make sure firewalld is started
service:
name: firewalld
state: started
- import_role:
name: update-firewall
- import_role:
name: update-dnsresolver-options
# - import_role:
# name: setup-dnsmasq
- import_role:
name: update-os
vars:
allow_reboot: true
tags:
- sysprep
- sysprep_linux
- import_playbook: sagenv-tools-disabletty.yaml