114 lines
3.0 KiB
YAML
114 lines
3.0 KiB
YAML
- name: Setup basic desktop environment
|
|
hosts: localhost
|
|
become_method: sudo
|
|
become: yes
|
|
tasks:
|
|
- name: install basic packages
|
|
apt:
|
|
name:
|
|
- sway
|
|
- swaylock
|
|
- waybar
|
|
- wofi
|
|
- alacritty
|
|
- git
|
|
- stow
|
|
- curl
|
|
- firefox-esr
|
|
- fish
|
|
- ripgrep
|
|
- exa
|
|
- bat
|
|
- xwayland
|
|
- swayidle
|
|
- fonts-ubuntu
|
|
- fonts-font-awesome
|
|
- lightdm
|
|
- xwayland
|
|
- wl-clipboard
|
|
- name: Get dotfiles
|
|
git:
|
|
dest: ~/dotfiles
|
|
repo: https://git.v-tr.org/violet/dotfiles
|
|
update: false
|
|
become: no
|
|
- name: setup dotfiles
|
|
command:
|
|
cmd: stow {{ item.name }}
|
|
chdir: ~/dotfiles
|
|
creates: "{{ item.path }}"
|
|
with_items:
|
|
- { name: alacritty, path: ~/.config/alacritty }
|
|
- { name: fish, path: ~/.config/fish }
|
|
- { name: git, path: ~/.config/git }
|
|
- { name: nvim, path: ~/.config/nvim }
|
|
- { name: sway, path: ~/.config/sway }
|
|
- { name: wofi, path: ~/.config/wofi }
|
|
- { name: borg, path: ~/.borg }
|
|
- { name: gtk, path: ~/.config/gtk-3.0 }
|
|
- { name: waybar, path: ~/.config/waybar }
|
|
become: no
|
|
- name: set default shell
|
|
user:
|
|
name: vi
|
|
shell: /usr/bin/fish
|
|
- name: Set power button behavior
|
|
lineinfile:
|
|
line: "HandlePowerKey=hibernate"
|
|
path: "/etc/systemd/logind.conf"
|
|
regexp: '.*HandlePowerKey.*'
|
|
- name: set lidswitch behavior
|
|
lineinfile:
|
|
line: "HandleLidSwitch=suspend-then-hibernate"
|
|
path: "/etc/systemd/logind.conf"
|
|
regexp: '.*HandleLidSwitch.*'
|
|
- name: set hibernation delay
|
|
lineinfile:
|
|
line: "HibernationDelaySec=7200"
|
|
path: "/etc/systemd/sleep.conf"
|
|
regexp: '.*HibernationDelaySec.*'
|
|
- name: istall more packages
|
|
apt:
|
|
name:
|
|
- firefox-esr
|
|
- keepassxc
|
|
- flatpak
|
|
- vlc
|
|
- nautilus
|
|
- nautilus-share
|
|
- gnome-keyring
|
|
- seahorse
|
|
- eog
|
|
- evince
|
|
- pipewire-audio
|
|
- pipewire-pulse
|
|
- thunderbird
|
|
- yt-dlp
|
|
- pavucontrol
|
|
state: present
|
|
register: out
|
|
- name: enable wireplumber
|
|
systemd_service:
|
|
name: wireplumber.service
|
|
enabled: yes
|
|
state: started
|
|
scope: user
|
|
become: no
|
|
- name: setup autologin
|
|
lineinfile:
|
|
path: /etc/lightdm/lightdm.conf
|
|
line: autologin-user=vi
|
|
regexp: '.*autologin-user.*'
|
|
insertafter: '^\[Seat:\*\]$'
|
|
- name: setup flathub
|
|
flatpak_remote:
|
|
name: flathub
|
|
flatpakrepo_url: https://dl.flathub.org/repo/flathub.flatpakrepo
|
|
- name: install flatpaks
|
|
flatpak:
|
|
name:
|
|
- im.riot.Riot
|
|
- org.signal.Signal
|
|
- com.synology.SynologyDrive
|
|
- com.github.tchx84.Flatseal
|