yavdr-ansible/roles/yavdr-xorg/tasks/setup-xorg.yml

106 lines
3.0 KiB
YAML
Raw Normal View History

---
# file: roles/yavdr-xorg/tasks/setup-xorg.yml
- name: create directories for systemd drop-in files
2017-07-30 14:29:38 +02:00
file:
dest: '{{ item }}'
2017-07-30 14:29:38 +02:00
state: directory
with_items:
- "/etc/systemd/system/x@.service.d/"
- "/etc/systemd/system/vdr.service.d/"
- "/etc/systemd/system/user@{{ vdr.uid }}.service.d/"
- "/etc/X11/xorg.conf.d/"
- name: systemd-drop-in | add dependency to X-server for vdr.service
2017-07-30 14:29:38 +02:00
template:
src: templates/vdr-xorg.conf
dest: /etc/systemd/system/vdr.service.d/vdr-xorg.conf
- name: systemd-drop-in | start x@.service after plymouth.service
template:
src: templates/x@service.d/plymouth.conf.j2
dest: /etc/systemd/system/x@.service.d/plymouth.conf
- name: systemd-drop-in | start x@.service before xlogin@.service
template:
src: templates/x@service.d/xlogin.conf.j2
dest: /etc/systemd/system/x@.service.d/xlogin.conf
- name: systemd-drop-in | load environment file for vdr.service
2017-07-30 14:29:38 +02:00
template:
src: templates/systemd/vdr-environ.j2
dest: /etc/systemd/system/vdr.service.d/load-environ.conf
- name: systemd-drop-in | user@{{ vdr.uid }}.service depends on x@vt7.service
template:
2017-07-31 11:52:04 +02:00
src: templates/user@666.service.d/x-dependency.conf.j2
dest: '/etc/systemd/system/user@{{ vdr.uid }}.service.d/x-dependency.conf'
- name: vdr-config | start softhddevice detached and set audio to pulseaudio
2017-07-31 08:22:05 +02:00
lineinfile:
path: /etc/vdr/conf.avail/softhddevice.conf
2017-12-17 11:37:28 +01:00
line: '{{ item }}'
2017-07-31 08:22:05 +02:00
with_items:
- '-D'
- '-w alsa-driver-broken'
2017-07-31 08:22:05 +02:00
# - '-a pulse' # do we need this with our existing asound.conf?
- name: add a login shell for the user vdr
2017-07-30 14:29:38 +02:00
user:
name: '{{ vdr.user }}'
shell: '/bin/bash'
state: present
uid: '{{ vdr.uid }}'
groups: '{{ vdr.group }}'
append: yes
- name: apt | install packages for xorg
2017-07-30 14:29:38 +02:00
apt:
name:
- xlogin
- yavdr-xorg
- xorg
- xserver-xorg-input-all
- xserver-xorg-video-all
- openbox
- python3-dbus2vdr
- python3-yavdrfrontend
- read-edid
- tmux
- vdr-plugin-desktop
- vdr-plugin-osd2web
- feh
#- yavdr-xorg
2017-07-30 14:29:38 +02:00
state: present
2018-04-20 15:26:52 +02:00
- name: apt | install packages for Intel IGP
apt:
name:
- xserver-xorg-video-intel
- i965-va-driver-shaders
state: present
when: intel_detected
- name: Install yaVDR Media (e.g. Backgrounds)
apt:
name: yavdr-media
2017-12-20 13:18:30 +01:00
- name: command | write keyboard configuration to /etc/X11/xorg.conf.d/00-keyboard.conf
command: write-x11-keyboard-config
args:
creates: /etc/X11/xorg.conf.d/00-keyboard.conf
# NOTE: write-x11-keyboard-config is in the xlogin package
# Ubuntu's systemd is patched, so it does not create the file automatically
- name: add snippet to ignore eventlircd devices in xorg
template:
src: templates/xorg-ignore-eventlircd.conf.j2
dest: /etc/X11/xorg.conf.d/40-ignore-eventlircd.conf
- name: apt | install desktop programs
apt:
name:
- xterm
- firefox
- kiosk-browser
state: present