2015-12-30 16:11:33 +00:00
|
|
|
---
|
|
|
|
- include: download.yml
|
2015-12-31 09:28:47 +00:00
|
|
|
run_once: true
|
|
|
|
delegate_to: "{{ groups['downloader'][0] }}"
|
2015-12-30 16:11:33 +00:00
|
|
|
|
2015-12-30 21:15:18 +00:00
|
|
|
- name: "Identify init system"
|
|
|
|
shell: >
|
|
|
|
if $(pgrep systemd > /dev/null); then
|
|
|
|
echo systemd;
|
|
|
|
else echo sysvinit;
|
|
|
|
fi
|
|
|
|
always_run: True
|
|
|
|
register: init_system_output
|
2015-12-30 16:11:33 +00:00
|
|
|
|
2015-12-30 21:15:18 +00:00
|
|
|
- set_fact:
|
|
|
|
init_system: "{{ init_system_output.stdout }}"
|
|
|
|
|
|
|
|
- name: Install debian packages requirements
|
|
|
|
apt:
|
2015-12-30 16:11:33 +00:00
|
|
|
name: "{{ item }}"
|
2015-12-30 21:15:18 +00:00
|
|
|
state: latest
|
|
|
|
when: ansible_os_family == "Debian"
|
|
|
|
with_items: req_debian_pkg
|
|
|
|
|
|
|
|
- include: python-bootstrap.yml
|
|
|
|
when: ansible_os_family not in [ "Debian", "RedHat" ]
|