Skip to content

komachi/ansible-decent-desktop

Repository files navigation

ansible-decent-desktop

This is an experiment to make desktop/laptop configuration fully controllable by Ansible. Also to experiment with GNU/Linux-based web-3/dapp/defi/security-first/insert-your-buzzword-here setup. Also because it's a lot of work to configure everything each time. Also because I can.

This project is not intended to fulfil desires of every user. I use it to provision my own personal PC. You probably find some defaults incompatible with your view on desktop OS configuration, but you can fork and tune it for yourself, or just look at playbooks for inspirations. PRs with improvements welcomed btw.

This playbook meant to be run against Debian bookworm. It probably won't work for other distros/versions, but you can try.

It focus both on security and speed when it's possible. It uses lightweight software when possible and some specific tuning to meet the goal. Take note that while this README uses word "security" several times, nobody checked this. Think then do.

It enables autologin and intended to use only on single-user desktop machines. Use it only with full-disk encryption and if you are single user. Not only for that reason, the whole playbook is meant to be deployed on a single-user desktop machine.

Software included

You should look for sources for full list, but here are some choices I made:

Roles

main.yml includes it all.

Playbook also depends on some roles defined in submodules, so you should also consult related upstream docs.

remote_keyring

Install some additional keyrings.

apt_transport_tor

Enable and enforce apt-transport-tor.

boot_manager

Configure boot manager.

audio

Configure audio settings.

logind

Configure logind.

additional_locales

Sets some additional locale settings not supported by debops.

networking

Configure networking.

mullvad

Configure mullvad VPN.

firewall

Configure nftables.

dm

Configure our dm replacement.

de

Configure window manager and other goodies usually provided by desktop environment.

packages

Configure specific packages. Most of packages configured here.

games

Install and configure some games.

themes

Configure themes.

fonts

Configure fonts.

hardware

Configure hardware.

timezone

Set timezone.

apparmor_profiles

Install additional apparmor profiles

Desktop and security improvements

This playbook meant to be used on desktops, so there is specific desktop-friendly settings made. Most of packages are also configured specifically to address security or speed, but here is some things to note

Test in VM

It can be run in VirtualBox with help of Vagrant and Molecule.

poetry install
poetry run molecule converge

Lint

sh lint.sh

Run locally

sudo apt install git python3-poetry
cd $(mktemp -d)
git clone https://github.com/komachi/ansible-decent-desktop.git
cd ansible-decent-desktop
sh run.sh