From ae89d739f205f74328b9a512881f6e599c612abd Mon Sep 17 00:00:00 2001 From: Florian Bergmann Date: Wed, 15 Nov 2023 21:39:37 +0100 Subject: [PATCH] Add Archlinux for surface tablet. --- roles/codecs/tasks/install_Debian.yml | 11 ---------- roles/codecs/tasks/main.yml | 3 ++- roles/emacs/tasks/Debian.yml | 8 -------- roles/fonts/tasks/Archlinux.yml | 5 ----- roles/fonts/tasks/Debian.yml | 19 ------------------ roles/gnome/tasks/install_Archlinux.yml | 14 +++++++++++++ roles/gnome/tasks/install_Debian.yml | 17 ---------------- roles/gnome/tasks/install_RedHat.yml | 1 + roles/gnome/tasks/main.yml | 5 ----- roles/gpg/tasks/install_Archlinux.yml | 7 +++++++ roles/gpg/tasks/install_Debian.yml | 8 -------- roles/kde/tasks/install_Debian.yml | 8 -------- roles/kubedev/tasks/install_cli.yml | 1 + .../tasks/install_minikube_Archlinux.yml | 6 ++++++ .../kubedev/tasks/install_minikube_Debian.yml | 5 ----- .../kubedev/tasks/repositories_cli_Debian.yml | 12 ----------- roles/lutris/tasks/Debian.yml | 11 ---------- roles/lutris/tasks/Ubuntu.yml | 6 ------ roles/pass/vars/Debian.yml | 1 - roles/sbt/tasks/Debian.yml | 20 ------------------- roles/scala/tasks/Debian.yml | 5 ----- roles/shell-tools/tasks/Debian.yml | 9 --------- roles/virtualization/tasks/main.yml | 18 ++++------------- roles/virtualization/vars/Archlinux.yml | 5 +++++ roles/virtualization/vars/Debian.yml | 4 ---- roles/zsh/tasks/install_theme.yml | 1 + 26 files changed, 41 insertions(+), 169 deletions(-) delete mode 100644 roles/codecs/tasks/install_Debian.yml delete mode 100644 roles/emacs/tasks/Debian.yml delete mode 100644 roles/fonts/tasks/Debian.yml create mode 100644 roles/gnome/tasks/install_Archlinux.yml delete mode 100644 roles/gnome/tasks/install_Debian.yml delete mode 100644 roles/gpg/tasks/install_Debian.yml delete mode 100644 roles/kde/tasks/install_Debian.yml create mode 100644 roles/kubedev/tasks/install_minikube_Archlinux.yml delete mode 100644 roles/kubedev/tasks/install_minikube_Debian.yml delete mode 100644 roles/kubedev/tasks/repositories_cli_Debian.yml delete mode 100644 roles/lutris/tasks/Debian.yml delete mode 100644 roles/lutris/tasks/Ubuntu.yml delete mode 100644 roles/pass/vars/Debian.yml delete mode 100644 roles/sbt/tasks/Debian.yml delete mode 100644 roles/scala/tasks/Debian.yml delete mode 100644 roles/shell-tools/tasks/Debian.yml create mode 100644 roles/virtualization/vars/Archlinux.yml delete mode 100644 roles/virtualization/vars/Debian.yml diff --git a/roles/codecs/tasks/install_Debian.yml b/roles/codecs/tasks/install_Debian.yml deleted file mode 100644 index a25b45f..0000000 --- a/roles/codecs/tasks/install_Debian.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - -- name: Install gstreamer plugins - package: - name: "{{ item }}" - state: present - with_items: - - gstreamer1.0-plugins-bad - - gstreamer1.0-plugins-base - - gstreamer1.0-plugins-good - - gstreamer1.0-plugins-ugly \ No newline at end of file diff --git a/roles/codecs/tasks/main.yml b/roles/codecs/tasks/main.yml index 6cbb840..27b0257 100644 --- a/roles/codecs/tasks/main.yml +++ b/roles/codecs/tasks/main.yml @@ -1,4 +1,5 @@ --- - name: Install based on distribution - include_tasks: "install_{{ ansible_os_family }}.yml" \ No newline at end of file + include_tasks: "install_{{ ansible_os_family }}.yml" + when: ansible_os_family != "Archlinux" diff --git a/roles/emacs/tasks/Debian.yml b/roles/emacs/tasks/Debian.yml deleted file mode 100644 index bb97ccb..0000000 --- a/roles/emacs/tasks/Debian.yml +++ /dev/null @@ -1,8 +0,0 @@ -- name: Install emacs package - package: - name: - - emacs - - cmake - - libtool-bin - - libvterm-dev - state: present diff --git a/roles/fonts/tasks/Archlinux.yml b/roles/fonts/tasks/Archlinux.yml index 85900a8..fee146c 100644 --- a/roles/fonts/tasks/Archlinux.yml +++ b/roles/fonts/tasks/Archlinux.yml @@ -16,8 +16,3 @@ package: name: ttf-font-awesome state: present - -- name: Install unifont - package: - name: bdf-unifont - state: present diff --git a/roles/fonts/tasks/Debian.yml b/roles/fonts/tasks/Debian.yml deleted file mode 100644 index e62de58..0000000 --- a/roles/fonts/tasks/Debian.yml +++ /dev/null @@ -1,19 +0,0 @@ -- name: Install Fira font - package: - name: "fonts-firacode" - state: present - -- name: Install Linux Libertine font - package: - name: "fonts-linuxlibertine" - state: present - -- name: Install font awesome - package: - name: "fonts-font-awesome" - state: present - -- name: Install font powerline - package: - name: "fonts-powerline" - state: present diff --git a/roles/gnome/tasks/install_Archlinux.yml b/roles/gnome/tasks/install_Archlinux.yml new file mode 100644 index 0000000..23f54e0 --- /dev/null +++ b/roles/gnome/tasks/install_Archlinux.yml @@ -0,0 +1,14 @@ +--- + +- name: Install the Gnome group + package: + name: + - dconf-editor + - gnome-shell-extension-appindicator + - gnome-shell-extension-forge + # Needed by the pop-shell extension + - pinentry + - firefox + - firefox-ublock-origin + - python-psutil + state: present diff --git a/roles/gnome/tasks/install_Debian.yml b/roles/gnome/tasks/install_Debian.yml deleted file mode 100644 index b697b0b..0000000 --- a/roles/gnome/tasks/install_Debian.yml +++ /dev/null @@ -1,17 +0,0 @@ ---- - -- name: Install the Gnome task - package: - name: - - task-gnome-desktop - - dconf-editor - - dconf-gsettings-backend - - gnome-software-plugin-flatpak - - gnome-shell-pomodoro - - gnome-shell-extensions - - gnome-shell-extension-appindicator - - pinentry-gnome3 - - firefox - - webext-https-everywhere - - webext-ublock-origin - state: present diff --git a/roles/gnome/tasks/install_RedHat.yml b/roles/gnome/tasks/install_RedHat.yml index d73e54b..88fa846 100644 --- a/roles/gnome/tasks/install_RedHat.yml +++ b/roles/gnome/tasks/install_RedHat.yml @@ -13,4 +13,5 @@ - pinentry-gnome3 - firefox - mozilla-ublock-origin + - python3-psutil state: present diff --git a/roles/gnome/tasks/main.yml b/roles/gnome/tasks/main.yml index f23e61b..c073a26 100644 --- a/roles/gnome/tasks/main.yml +++ b/roles/gnome/tasks/main.yml @@ -2,11 +2,6 @@ - name: Install gnome-desktop include_tasks: "install_{{ ansible_os_family }}.yml" -- name: Install required packages to use dconf - package: - name: python3-psutil - state: present - - name: Write gnome settings become: yes become_user: "{{ desktop_user.username }}" diff --git a/roles/gpg/tasks/install_Archlinux.yml b/roles/gpg/tasks/install_Archlinux.yml index a8c9a67..f619d4e 100644 --- a/roles/gpg/tasks/install_Archlinux.yml +++ b/roles/gpg/tasks/install_Archlinux.yml @@ -7,3 +7,10 @@ - gnupg - pcsc-tools - pcsclite + - ccid + +- name: Enable pcscd socket + service: + name: pcscd.socket + state: started + enabled: true diff --git a/roles/gpg/tasks/install_Debian.yml b/roles/gpg/tasks/install_Debian.yml deleted file mode 100644 index 8d36d0e..0000000 --- a/roles/gpg/tasks/install_Debian.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -- name: Install packages - package: - name: "{{ item }}" - state: present - with_items: - - gnupg - - scdaemon diff --git a/roles/kde/tasks/install_Debian.yml b/roles/kde/tasks/install_Debian.yml deleted file mode 100644 index 353f620..0000000 --- a/roles/kde/tasks/install_Debian.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- - -- name: Install Debian packages - package: - name: "{{ item }}" - state: present - with_items: - - kde-standard diff --git a/roles/kubedev/tasks/install_cli.yml b/roles/kubedev/tasks/install_cli.yml index f0f6e31..49e20c3 100644 --- a/roles/kubedev/tasks/install_cli.yml +++ b/roles/kubedev/tasks/install_cli.yml @@ -2,6 +2,7 @@ - name: Setup kubernetes repositories include_tasks: "repositories_cli_{{ ansible_os_family }}.yml" + when: ansible_distribution != "Archlinux" - name: Install kubectl package: diff --git a/roles/kubedev/tasks/install_minikube_Archlinux.yml b/roles/kubedev/tasks/install_minikube_Archlinux.yml new file mode 100644 index 0000000..1d0cab0 --- /dev/null +++ b/roles/kubedev/tasks/install_minikube_Archlinux.yml @@ -0,0 +1,6 @@ +--- + +- name: Install minikube + package: + name: minikube + state: present diff --git a/roles/kubedev/tasks/install_minikube_Debian.yml b/roles/kubedev/tasks/install_minikube_Debian.yml deleted file mode 100644 index fc0943c..0000000 --- a/roles/kubedev/tasks/install_minikube_Debian.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- - -- name: Install minikube - apt: - deb: "https://storage.googleapis.com/minikube/releases/latest/minikube_{{ minikube_version }}-0_amd64.deb" diff --git a/roles/kubedev/tasks/repositories_cli_Debian.yml b/roles/kubedev/tasks/repositories_cli_Debian.yml deleted file mode 100644 index 612dc36..0000000 --- a/roles/kubedev/tasks/repositories_cli_Debian.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- - -- name: Add kubernetes gpg key - apt_key: - url: https://packages.cloud.google.com/apt/doc/apt-key.gpg - state: present - -- name: Setup kubectl repository - apt_repository: - repo: deb https://apt.kubernetes.io/ kubernetes-xenial main - state: present - filename: kubernetes diff --git a/roles/lutris/tasks/Debian.yml b/roles/lutris/tasks/Debian.yml deleted file mode 100644 index 17247c3..0000000 --- a/roles/lutris/tasks/Debian.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- - -- name: Import repository key - apt_key: - url: "https://download.opensuse.org/repositories/home:/strycore/Debian_{{ ansible_distribution_version }}/Release.key" - state: present - -- name: Add lutris build service repository for Debian - apt_repository: - repo: "deb http://download.opensuse.org/repositories/home:/strycore/Debian_{{ ansible_distribution_version }}/ ./" - state: present diff --git a/roles/lutris/tasks/Ubuntu.yml b/roles/lutris/tasks/Ubuntu.yml deleted file mode 100644 index 2a95f27..0000000 --- a/roles/lutris/tasks/Ubuntu.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- - -- name: Add lutris build service repository for Ubuntu - apt_repository: - repo: "ppa:lutris-team/lutris" - state: present diff --git a/roles/pass/vars/Debian.yml b/roles/pass/vars/Debian.yml deleted file mode 100644 index 7fc4c06..0000000 --- a/roles/pass/vars/Debian.yml +++ /dev/null @@ -1 +0,0 @@ -packages: ["pass"] diff --git a/roles/sbt/tasks/Debian.yml b/roles/sbt/tasks/Debian.yml deleted file mode 100644 index 18cf240..0000000 --- a/roles/sbt/tasks/Debian.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- -- name: Install dependencies to manage repositories - package: - name: "{{ item }}" - state: present - with_items: ["gnupg2", "apt-transport-https"] - -- name: Add sbt bintray key - apt_key: - keyserver: hkp://keyserver.ubuntu.com:80 - id: 2EE0EA64E40A89B84B2DF73499E82A75642AC823 - -- name: Add sbt bintray repository - apt_repository: - repo: deb "https://dl.bintray.com/sbt/debian" / - state: present - -- name: Update apt cache - apt: - update_cache: yes diff --git a/roles/scala/tasks/Debian.yml b/roles/scala/tasks/Debian.yml deleted file mode 100644 index fecff1b..0000000 --- a/roles/scala/tasks/Debian.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: Install scala package - package: - name: scala - state: present diff --git a/roles/shell-tools/tasks/Debian.yml b/roles/shell-tools/tasks/Debian.yml deleted file mode 100644 index 56d1729..0000000 --- a/roles/shell-tools/tasks/Debian.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- - -- name: Install better command line tools - package: - name: "{{ item }}" - state: present - with_items: - - silversearcher-ag - - ripgrep diff --git a/roles/virtualization/tasks/main.yml b/roles/virtualization/tasks/main.yml index 2b7ad4a..868a5b4 100644 --- a/roles/virtualization/tasks/main.yml +++ b/roles/virtualization/tasks/main.yml @@ -4,25 +4,14 @@ # tasks file for roles/virtualization - name: Install required packages for virtualization - apt: + package: name: "{{ packages }}" state: present - update_cache: yes vars: packages: - virt-manager - - bridge-utils - - qemu-kvm - - libvirt-clients - - libvirt-daemon - - libvirt-daemon-system - - bridge-utils - - iptables - - virt-top - - virt-manager - # ansible dependencies: - - python-libvirt - when: ansible_os_family == "Debian" + - qemu-full + when: ansible_os_family == "Archlinux" - name: Install required packages for virtualization dnf: @@ -34,6 +23,7 @@ - "@Virtualization" when: ansible_os_family == "RedHat" + - name: Add {{ desktop_user.username }} to libvirt group user: name: "{{ desktop_user.username }}" diff --git a/roles/virtualization/vars/Archlinux.yml b/roles/virtualization/vars/Archlinux.yml new file mode 100644 index 0000000..9464ba9 --- /dev/null +++ b/roles/virtualization/vars/Archlinux.yml @@ -0,0 +1,5 @@ +--- +libvirt_groups: + - libvirt + - libvirt-qemu + - qemu diff --git a/roles/virtualization/vars/Debian.yml b/roles/virtualization/vars/Debian.yml deleted file mode 100644 index 4378c92..0000000 --- a/roles/virtualization/vars/Debian.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- -libvirt_groups: - - libvirt - - libvirt-qemu \ No newline at end of file diff --git a/roles/zsh/tasks/install_theme.yml b/roles/zsh/tasks/install_theme.yml index 726d02c..a65d848 100644 --- a/roles/zsh/tasks/install_theme.yml +++ b/roles/zsh/tasks/install_theme.yml @@ -5,6 +5,7 @@ community.general.copr: name: atim/starship state: enabled + when: ansible_os_family in ["RedHat"] - name: Install starship package: