ref(playbook): Change to role-based structure
This commit is contained in:
parent
95fd68bed8
commit
b3b280fbe4
39 changed files with 635 additions and 601 deletions
29
roles/display_manager/tasks/main.yaml
Normal file
29
roles/display_manager/tasks/main.yaml
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
---
|
||||
- name: Ensure user group for greeter exists
|
||||
ansible.builtin.group:
|
||||
name: "{{ greeter_user }}"
|
||||
state: present
|
||||
|
||||
- name: Install greetd and tuigreet
|
||||
community.general.xbps:
|
||||
name:
|
||||
- greetd
|
||||
- tuigreet
|
||||
state: present
|
||||
tags:
|
||||
- packages
|
||||
|
||||
- name: Set up tuigreet config for greetd
|
||||
ansible.builtin.template:
|
||||
src: greetd-config.toml.j2
|
||||
dest: "/etc/greetd/config.toml"
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0644
|
||||
force: true
|
||||
|
||||
- name: Activate greetd service
|
||||
ansible.builtin.file:
|
||||
src: "/etc/sv/greetd"
|
||||
dest: "/etc/runit/runsvdir/default/greetd"
|
||||
state: link
|
||||
18
roles/display_manager/templates/greetd-config.toml.j2
Normal file
18
roles/display_manager/templates/greetd-config.toml.j2
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
[terminal]
|
||||
# The VT to run the greeter on. Can be "next", "current" or a number
|
||||
# designating the VT.
|
||||
vt = 7
|
||||
|
||||
# The default session, also known as the greeter.
|
||||
[default_session]
|
||||
command = "tuigreet --cmd zsh"
|
||||
user = "{{ greeter_user }}"
|
||||
|
||||
# `agreety` is the bundled agetty/login-lookalike. You can replace `/bin/sh`
|
||||
# with whatever you want started, such as `sway`.
|
||||
# command = "agreety --cmd /bin/sh"
|
||||
|
||||
# The user to run the command as. The privileges this user must have depends
|
||||
# on the greeter. A graphical greeter may for example require the user to be
|
||||
# in the `video` group.
|
||||
#user = "_greeter"
|
||||
2
roles/display_manager/vars/main.yaml
Normal file
2
roles/display_manager/vars/main.yaml
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
---
|
||||
greeter_user: _greeter
|
||||
Loading…
Add table
Add a link
Reference in a new issue