-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathmain.yml
70 lines (57 loc) · 2.17 KB
/
main.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
- name: Set flag for fedora 18
set_fact:
is_F18: True
when: ansible_distribution_release == "based on Fedora 18" or ansible_distribution_version == "18"
- include: selinux.yml
when: ansible_selinux is defined and ansible_version >= '2' and ansible_selinux or ansible_selinux['status'] is defined and ansible_version < '2' and ansible_selinux['status'] != 'disabled'
- include: fl.yml
- include: prep.yml
- include: xsce_ini.yml
- name: Keep yum cache
ini_file: dest=/etc/yum.conf
section=main
option=keepcache
value=1
- include: xo.yml
when: xo_model != "none" or osbuilder is defined
- include: centos.yml
when: ansible_distribution == "CentOS"
- include: fedora.yml
when: ansible_distribution == "Fedora"
- include: fix_ansible_version.yml
- include: chrony.yml
- include: prelim.yml
- include: yum.yml
- include: cmdsrv.yml
- include: patch_udev.yml
- include: net_mods.yml
# Put conditional includes for platforms here
## DISCOVER PLATFORMS ######
- name: Discover if this is a rpi2 -- if so it has a bcm2709 processor
set_fact:
rpi_model: "rpi2"
when: ansible_cmdline["bcm2709.serial"] is defined
ignore_errors: true
- name: Check of the identifier for tplink725 is present
shell: "lsusb | grep 0bda:8179 | wc |gawk '{print $1}'"
register: usb_response
ignore_errors: true
- name: Use compiled hostapd, and wpa_supplicant if tplink WM725M
set_fact:
wifi_id: tplink_WM725M
when: usb_response.stdout|int > 0
- include: hw_rpi2.yml
when: rpi_model is defined and rpi_model == "rpi2"
- name: Check if the identifier for intel's NUC6 builtin wifi is present
shell: "lsusb | grep 8087:0a2b | wc |gawk '{print $1}'"
register: usb_NUC6
ignore_errors: true
- name: download the firmware for built in wifi on NUC6
get_url: dest=/lib/firmware
url={{ xsce_download_url }}/iwlwifi-8000C-13.ucode
when: usb_NUC6.stdout|int > 0
# need to add proper download section and get the binary out of git
- name: copy the firmware for tplink WM752M
copy: src=rtl8188eufw.bin dest=/lib/firmware/rtlwifi/
when: wifi_id == "tplink_WM725M" and xo_model == "none" and not rpi_model is defined
ignore_errors: true