feat: systemd, unbound, more packages, dots venv

This commit is contained in:
Matthieu Bessat 2024-05-30 18:28:31 +02:00
parent 45076c5231
commit 9c4a6a4341
15 changed files with 291 additions and 48 deletions

View file

@ -0,0 +1,32 @@
- name: Setup unbound config
become: true
copy:
src: "{{ home }}/.dots/config/unbound/unbound.conf"
dest: "/etc/unbound/unbound.conf"
owner: unbound
mode: "u=rwX,g=rX,o="
- name: Setup unbound control certificates
become: true
shell: /usr/bin/unbound-control-setup
- name: Specify resolv configuration to use the local unbound server
become: true
copy:
dest: /etc/resolv.conf
content: |
nameserver ::1
nameserver 127.0.0.1
- name: Protect resolv
become: true
file:
path: /etc/resolv.conf
attributes: '+i'
- name: Enable unbound service
become: true
ansible.builtin.systemd_service:
name: unbound
state: started
enabled: true

View file

@ -6,3 +6,9 @@
ansible.builtin.git:
repo: "git@forge.lefuturiste.fr:mbess/main-popequer-notebook.git"
dest: /home/mbess/notebooks/personal
- name: Setup gitwatch
systemd_service:
scope: user
name: popequer_gitwatch@personal
state: started
enabled: true

View file

@ -1,5 +0,0 @@
- name: Setup unbound config
file:
src: "{{ home }}/.dots/config/unbound/unbound.conf"
dest: "/etc/unbound/unbound.conf"
state: link

View file

@ -1,7 +1,27 @@
- name: Install xremap via AUR
import_role:
name: aur
vars:
packages:
- xremap-wlroots-bin
- name: Setup xremap dir
file:
path: "{{ home }}/.config/xremap"
state: directory
recurse: true
- name: Generate xremap config
shell: "python3 {{ home }}/.dots/scripts/generate_xremap_config.py"
- name: Setup xremap systemd
- name: Generate xremap systemd service unit
become: true
template:
src: systemd/system/xremap.service
dest: /usr/lib/systemd/system/xremap.service
- name: Enable xremap systemd service
become: true
ansible.builtin.systemd_service:
name: xremap
state: started