You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

152 lines
8.7 KiB
YAML

---
# do not remove the string "zhutop" from the name - I use it to identify this play
# in logic statements in the various roles used by this play
- name: Academic playbook zhutop
hosts: all
pre_tasks:
- name: Write a start message to the playbook log
ansible.builtin.shell: >
printf "\nStarted playbook '{{ ansible_play_name }}' execution at {{ now() }}\n"
>> ./log/{{ inventory_hostname }}.log
run_once: true
delegate_to: localhost
args:
chdir: "{{ playbook_dir }}"
become: true
become_user: "{{ local_user }}"
changed_when: true
tags: always
roles:
# https://codeberg.org/ansible/common
- { role: common, become: true, tags: [ common ] }
# https://codeberg.org/ansible/common-systools
- { role: common-systools, become: true, tags: [ common ] }
- { role: dotfiles, tags: [ dotfiles ] }
# https://codeberg.org/ansible/locales
- { role: locales, become: true, tags: [ locales ] }
# https://codeberg.org/ansible/ssh
- { role: ssh, become: true, tags: [ ssh ] }
# https://codeberg.org/ansible/swap
- { role: swap, become: true, tags: [ swap ] }
## i3 and window manager-related
# https://codeberg.org/ansible/desktop-environment
- { role: desktop-environment, become: true, tags: [ desktop-environment ] }
# https://codeberg.org/ansible/i3wm
- { role: i3wm, become: true, tags: [ i3wm ] }
# https://codeberg.org/ansible/boot-grub
- { role: boot-grub, become: true, tags: [ boot-grub ] }
# https://codeberg.org/ansible/flatpak-remote
- { role: flatpak-remote, become: true, tags: [ flatpak-remote ] }
# https://codeberg.org/ansible/fonts
- { role: fonts, become: true, tags: [ fonts ] }
#### software
# https://codeberg.org/ansible/qbittorrent
- { role: qbittorrent, become: true, tags: [ qbittorrent ] }
post_tasks:
- name: Log the current commit of '{{ ansible_play_name }}' playbook
local_action: >
shell git log
--pretty="Playbook '{{ playbook_dir | basename }}' last commit %h %ci by %cn" -1
>> ./log/{{ inventory_hostname }}.log
args:
chdir: "{{ playbook_dir }}"
become: true
become_user: "{{ local_user }}"
tags: always
- name: Write an end message to the playbook log
ansible.builtin.shell: >
echo "Ended playbook '{{ ansible_play_name }}' execution at {{ now() }}"
>> ./log/{{ inventory_hostname }}.log
run_once: true
delegate_to: localhost
args:
chdir: "{{ playbook_dir }}"
become: true
become_user: "{{ local_user }}"
changed_when: true
tags: always
# - { role: cups, become: true, tags: [ cups ] }
# - { role: pulseaudio, become: true, tags: [ pulseaudio ] }
# - { role: samba, become: true, tags: [ samba ] }
# - { role: tailscale, become: true, tags: [ tailscale ] }
# #### software
# - { role: ansible, become: true, tags: [ ansible ] }
# - { role: bluetooth, become: true, tags: [ bluetooth ] }
# # - { role: browser-agregore, become: true, tags: [ browser-agregore ] }
# - { role: browser-beaker, become: true, tags: [ browser-beaker, beaker ] }
# - { role: browser-brave, become: true, tags: [ browser-brave, brave ] }
# - { role: browser-chrome, become: true, tags: [ browser-chrome, chrome ] }
# - { role: browser-chromium, become: true, tags: [ browser-chromium, chromium ] }
# - { role: browser-firefox, become: true, tags: [ browser-firefox, firefox ] }
# - { role: browser-min, become: true, tags: [ browser-min ] }
# - { role: browser-opera, become: true, tags: [ browser-opera ] }
# - { role: browser-vivaldi, become: true, tags: [ browser-vivaldi ] }
# - { role: desktop-tools, become: true, tags: [ desktop-tools ] }
# - { role: digikam, become: true, tags: [ digikam ] }
# - { role: editor-atom, become: true, tags: [ editor-atom, atom ] }
# - { role: editor-nano, become: true, tags: [ editor-nano, nano ] }
# - { role: editor-sublime, become: true, tags: [ editor-sublime, sublime ] }
# - { role: editor-vscodium, become: true, tags: [ editor-vscodium, vscodium ] }
# - { role: element-desktop, become: true, tags: [ element-desktop ] }
# - { role: etcher, become: true, tags: [ etcher ] }
# - { role: ffmpeg, become: true, tags: [ ffmpeg ] }
# - { role: fsearch, become: true, tags: [ fsearch ] }
# # - { role: firejail, become: true, tags: [ firejail ] }
# - { role: fityk, become: true, tags: [ fityk ] }
# ## use thorium instead
# # - { role: foliate-ebookreader, become: true, tags: [ foliate-ebookreader, foliate ] }
# - { role: freemind, become: true, tags: [ freemind ] }
# - { role: freerdp, become: true, tags: [ freerdp ] }
# - { role: google-earth, become: true, tags: [ google-earth ] }
# - { role: gprename, become: true, tags: [ gprename ] }
# - { role: handbrake, become: true, tags: [ handbrake ] }
# - { role: imagemagick, become: true, tags: [ imagemagick ] }
# - { role: iriun-webcam, become: true, tags: [ iriun-webcam, iriun ] }
# - { role: java-openjdk, become: true, tags: [ java-openjdk ] }
# - { role: jupyterlab-desktop, become: true, tags: [ jupyterlab-desktop ] }
# - { role: libreoffice, become: true, tags: [ libreoffice ] }
# - { role: magnus, become: true, tags: [ magnus ] } # screen magnifier
# - { role: mpv, become: true, tags: [ mpv ] }
# # - { role: nextcloud-desktop, become: true, tags: [ nextcloud-desktop ] }
# # - { role: nuclear-musicplayer, become: true, tags: [ nuclear-musicplayer, nuclear ] }
# - { role: okular, become: true, tags: [ okular ] }
# - { role: pandoc, become: true, tags: [ pandoc ] }
# - { role: pcmanfm, become: true, tags: [ pcmanfm ] }
# - { role: pdftk, become: true, tags: [ pdftk ] }
# - { role: peek, become: true, tags: [ peek ] } # animated GIF recorder
# # picom only relevant with i3wm (not if using Desktop Environment)
# # - { role: picom, become: true, tags: [ picom ] }
# # pipe-viewer contains interactive step, needs workaround
# - { role: pipe-viewer, become: true, tags: [ pipe-viewer ] }
# - { role: qownnotes, become: true, tags: [ qownnotes ] }
# - { role: R, become: true, tags: [ R ] }
# - { role: radian, become: true, tags: [ radian ] }
# - { role: rofi-calc, tags: [ rofi-calc ] }
# - { role: scrcpy, become: true, tags: [ scrcpy ] }
# - { role: screenkey, become: true, tags: [ screenkey ] }
# - { role: shutter, become: true, tags: [ shutter ] }
# - { role: signal-desktop, become: true, tags: [ signal-desktop ] }
# - { role: sioyek-pdf, become: true, tags: [ sioyek-pdf ] }
# - { role: speech-to-text, become: true, tags: [ speech-to-text ] }
# - { role: thorium-reader, become: true, tags: [ thorium-reader ] }
# - { role: thunderbird, become: true, tags: [ thunderbird ] }
# - { role: tmux-xpanes, become: true, tags: [ tmux-xpanes ] }
# - { role: ultimaker-cura, become: true, tags: [ ultimaker-cura ] }
# - { role: unison, become: true, tags: [ unison ] }
# # consider whether vino is required for remote desktop
# # - { role: vino, become: true, tags: [ vino ] }
# - { role: virtualbox, become: true, tags: [ virtualbox ] }
# - { role: vlc, become: true, tags: [ vlc, vlc-videolan ] }
# - { role: x2goclient, become: true, tags: [ x2goclient ] }
# - { role: x2goserver, become: true, tags: [ x2goserver ] }
# - { role: xournalpp, become: true, tags: [ xournalpp ] }
# # zathura PDF viewer
# - { role: zathura, become: true, tags: [ zathura ] }
# - { role: zoom-client, become: true, tags: [ zoom-client ] }
# - { role: zotero, become: true, tags: [ zotero ] }