2017-11-22 10:06:47 +01:00
|
|
|
---
|
|
|
|
# file roles/autoinstall-virtualbox-guest/tasks/main.yml
|
|
|
|
|
2019-03-26 09:17:59 +01:00
|
|
|
- name: collect facts about installed packages
|
|
|
|
package_facts:
|
|
|
|
manager: "apt"
|
|
|
|
|
2017-11-22 10:06:47 +01:00
|
|
|
- name: install virtualbox guest additions
|
|
|
|
block:
|
|
|
|
- name: install packages
|
|
|
|
apt:
|
|
|
|
state: present
|
2018-10-05 17:49:39 +02:00
|
|
|
name:
|
|
|
|
- dkms
|
2019-03-26 09:17:59 +01:00
|
|
|
- '{{ "virtualbox-guest-x11-hwe" if "xserver-xorg-hwe-18.04" in ansible_facts.packages else "virtualbox-guest-x11" }}'
|
|
|
|
- '{{ "virtualbox-guest-dkms-hwe" if "linux-generic-hwe-18.04" in ansible_facts.packages else "virtualbox-guest-dkms" }}'
|
2017-11-22 10:56:21 +01:00
|
|
|
|
|
|
|
# TODO: set xineliboutput as frontend
|
2017-11-22 10:06:47 +01:00
|
|
|
when:
|
|
|
|
- ansible_virtualization_type == "virtualbox"
|
|
|
|
- ansible_virtualization_role == "guest"
|
|
|
|
- ansible_distribution == "Ubuntu"
|
2018-02-12 16:37:41 +01:00
|
|
|
|
|
|
|
- name: set xineliboutput as frontend
|
2018-02-12 16:40:58 +01:00
|
|
|
block:
|
|
|
|
- apt:
|
2018-10-05 17:49:39 +02:00
|
|
|
name:
|
|
|
|
- vdr-plugin-xineliboutput
|
|
|
|
- xineliboutput-sxfe
|
2018-02-12 16:40:58 +01:00
|
|
|
state: present
|
|
|
|
- command: '{{ item }}'
|
|
|
|
with_items:
|
|
|
|
- vdrctl disable softhddevice
|
|
|
|
- vdrctl disable vaapidevice
|
|
|
|
- vdrctl disable xine
|
|
|
|
- vdrctl disable pvr350
|
|
|
|
- vdrctl enable xineliboutput
|
|
|
|
ignore_errors: yes
|
2018-02-12 16:37:41 +01:00
|
|
|
when:
|
2018-09-04 13:21:32 +02:00
|
|
|
- ansible_virtualization_type == "virtualbox" or ansible_virtualization_type == "VMware"
|
2018-02-12 16:37:41 +01:00
|
|
|
- ansible_virtualization_role == "guest"
|