2020-07-27 11:20:38 -05:00
|
|
|
#!/usr/bin/ansible-playbook
|
|
|
|
# vim:ft=ansible:
|
|
|
|
---
|
|
|
|
- name: Install and configure SDDM
|
|
|
|
block:
|
|
|
|
- name: Install SDDM
|
|
|
|
apt:
|
|
|
|
name:
|
|
|
|
- sddm
|
2020-07-29 07:02:23 -05:00
|
|
|
- name: Create config directory
|
|
|
|
file:
|
|
|
|
path: /etc/sddm.conf.d
|
|
|
|
state: directory
|
2020-07-27 11:47:34 -05:00
|
|
|
- name: Template out config
|
2020-07-27 11:20:38 -05:00
|
|
|
template:
|
2020-07-27 11:47:34 -05:00
|
|
|
src: main.conf
|
|
|
|
dest: /etc/sddm.conf.d/50-ansible.conf
|
2020-07-27 11:20:38 -05:00
|
|
|
mode: "0644"
|
2020-07-27 11:47:34 -05:00
|
|
|
- name: Install theme
|
|
|
|
block:
|
|
|
|
- name: Remove KDE config
|
|
|
|
file:
|
|
|
|
path: /etc/sddm.conf.d/kde_settings.conf
|
|
|
|
state: absent
|
|
|
|
- name: Download theme
|
|
|
|
get_url:
|
|
|
|
url: "{{ sddm_theme }}"
|
|
|
|
dest: "/usr/share/sddm/themes/ansible.zip"
|
|
|
|
register: t
|
|
|
|
- name: Unpack theme
|
|
|
|
unarchive:
|
|
|
|
src: "/usr/share/sddm/themes/ansible.zip"
|
|
|
|
dest: "/usr/share/sddm/themes"
|
|
|
|
remote_src: yes
|
|
|
|
when: t is changed
|
2020-07-27 11:55:20 -05:00
|
|
|
when: sddm_theme is defined
|
2020-07-27 11:56:13 -05:00
|
|
|
- name: Template out theme config
|
|
|
|
template:
|
|
|
|
src: theme.conf
|
|
|
|
dest: /etc/sddm.conf.d/51-ansible-theme.conf
|
|
|
|
mode: "0644"
|
2020-07-27 11:56:34 -05:00
|
|
|
when: sddm_theme_name is defined
|
2020-07-27 11:20:38 -05:00
|
|
|
become: yes
|