From 51af2fb0a28ace4e8aaab7198094a00571061d7f Mon Sep 17 00:00:00 2001 From: Tobias Maier Date: Tue, 14 Jun 2022 18:47:31 +0200 Subject: [PATCH] Cleanup --- arch_basics.yaml | 76 ----------------------- arch_river.yml | 153 ----------------------------------------------- inventory | 2 - 3 files changed, 231 deletions(-) delete mode 100644 arch_basics.yaml delete mode 100644 arch_river.yml delete mode 100644 inventory diff --git a/arch_basics.yaml b/arch_basics.yaml deleted file mode 100644 index cd2800b..0000000 --- a/arch_basics.yaml +++ /dev/null @@ -1,76 +0,0 @@ ---- -- hosts: localhost - vars: - - hostname: 'stargazer' - tasks: - - name: Update and Upgrade all exisiting packages - community.general.pacman: - update_cache: yes - upgrade: yes - - name: Install archlinux-keyring - community.general.pacman: - name: archlinux-keyring - state: latest - - name: Install basic packages - community.general.pacman: - name: sudo,zsh,htop,autoconf,automake,binutils,bison,file,findutils,flex,gawk,gcc,gettext,grep,groff,gzip,libtool,m4,make,patch,pkgconf,sed,texinfo,which,base-devel,ttf-font-awesome - state: present - - - name: Make sure we have a 'wheel' group - group: - name: wheel - state: present - - - name: Make sure we have a 'docker' group - group: - name: docker - state: present - - - name: Allow 'wheel' to be sudo - lineinfile: - dest: /etc/sudoers - state: present - regexp: '^%wheel' - line: '%wheel ALL=(ALL) ALL' - - - name: Add the user tobi - ansible.builtin.user: - name: tobi - password: $6$9OnvBMN6Sxc.muW1$afASAJdoPZL/WxTp6.lh/SurRRiClaru2Pl19fEo6j1aDEQw99kdkfls6.DB8OBacBDnT3bpsLYD3JqrvXlE9/ - comment: Tobias Maier - groups: wheel,docker - shell: /bin/zsh - - - name: Add name to git config - community.general.git_config: - name: user.name - scope: system - value: Tobias Maier - - - name: Add email to git config - community.general.git_config: - name: user.email - scope: system - value: admin@maiertobi.de - - - name: Create the `aur_builder` user - ansible.builtin.user: - name: aur_builder - create_home: yes - #group: wheel - - - name: Allow the `aur_builder` user to run `sudo pacman` without a password - ansible.builtin.lineinfile: - path: /etc/sudoers.d/11-install-aur_builder - line: 'aur_builder ALL=(ALL) NOPASSWD: /usr/bin/pacman' - create: yes - validate: 'visudo -cf %s' - - - name: Install paru using makepkg if it isn't installed already - kewlfft.aur.aur: - name: paru - use: makepkg - state: present - become: yes - become_method: su - become_user: aur_builder \ No newline at end of file diff --git a/arch_river.yml b/arch_river.yml deleted file mode 100644 index 70737c2..0000000 --- a/arch_river.yml +++ /dev/null @@ -1,153 +0,0 @@ ---- -- name: Initial installation RiverWM - hosts: localhost,all - become: yes - - pre_tasks: - - name: Run the equivalent of "pacman -Syu" as a separate step - community.general.pacman: - update_cache: yes - upgrade: yes - - name: Install packages - community.general.pacman: - name: sudo,htop,base-devel,git - state: present - - name: Make sure we have a 'wheel' group - group: - name: wheel - state: present - - name: Add the user tobi - ansible.builtin.user: - name: tobi - password: $6$jUZIIwoMDSg8B3OJ$tRKNJe.YHLVQRkbRSvmPJqE4lFUBVKKDxy.K688SW.gUP8VdfrkUeIIa7XqI8ovpncoZlt5VbGk7WxMKBCS191 - comment: Tobias Maier - groups: wheel,video - shell: /bin/zsh - - name: Add name to git config - community.general.git_config: - name: user.name - scope: global - value: Tobias Maier - - name: Add email to git config - community.general.git_config: - name: user.email - scope: global - value: git@maiertobi.de - - name: Create the `aur_builder` user - ansible.builtin.user: - name: aur_builder - create_home: yes - group: wheel - - name: Allow the `aur_builder` user to run `sudo pacman` without a password - ansible.builtin.lineinfile: - path: /etc/sudoers.d/11-install-aur_builder - line: 'aur_builder ALL=(ALL) NOPASSWD: /usr/bin/pacman' - create: yes - validate: 'visudo -cf %s' - - - name: Add number of CPUs to MAKEPKG - ansible.builtin.lineinfile: - path: /etc/makepkg.conf - line: 'MAKEFLAGS="-j$(nproc)"' - create: yes - - name: Install paru using makepkg if it isn't installed already - kewlfft.aur.aur: - name: paru - use: makepkg - state: present - become: yes - become_user: aur_builder - - name: Install reflector from AUR - community.general.pacman: - name: reflector - state: present - executable: paru - become: yes - become_user: aur_builder - - - name: Run reflector to update mirrorlist - ansible.builtin.command: reflector --latest 20 --sort rate --save /etc/pacman.d/mirrorlist - - - name: Install packages from AUR - kewlfft.aur.aur: - use: paru - name: zsh,exa,oh-my-zsh-git,zsh-theme-powerlevel10k-git,zsh-autosuggestions,zsh-syntax-highlighting,nano,ly,ansible,openssh,sway,foot,foot-terminfo,waybar,ttf-font-awesome,sway-launcher-desktop,pipewire,pipewire-pulse,bluez,bluez-utils,firefox,archlinux-wallpaper,iwd,btop,light,wob,udiskie,ranger,mako,vim,man,wdisplays,pamixer,qt5-wayland - state: latest - become: yes - become_user: aur_builder - - - name: Install RiverWM - kewlfft.aur.aur: - use: paru - name: river - state: latest - become: yes - become_user: aur_builder - - - name: Add WLR_RENDERER_ALLOW_SOFTWARE to /etc/environment, needed for testing in VM - ansible.builtin.lineinfile: - path: /etc/environment - regexp: '^WLR_RENDERER_ALLOW_SOFTWARE=' - line: WLR_RENDERER_ALLOW_SOFTWARE=1 - - name: Clone dotfiles - ansible.builtin.git: - repo: https://gitea.maiertobi.de/tobimai/dotfiles.git - dest: /home/tobi/git/dotfiles - - - - name: Ensures directories exist - ansible.builtin.file: - path: /home/tobi/{{ item }} - state: directory - group: tobi - owner: tobi - mode: '0744' - loop: - - .config/sway - - .config/foot - - .config/waybar - - .config/mako - - .config/river - - git - - name: Copy ZSH dotfiles - copy: - src: //home/tobi/git/dotfiles/{{ item.src }} - dest: /home/tobi/{{ item.dest }} - remote_src: yes - with_items: - - { src: '.zshrc', dest: '.zshrc' } - - { src: '.p10k.zsh', dest: '.p10k.zsh' } - - - - name: Copy config files - copy: - src: //home/tobi/git/dotfiles/{{ item.src }} - dest: /home/tobi/.config/{{ item.dest }} - remote_src: yes - owner: tobi - group: tobi - with_items: - - { src: 'sway_config', dest: 'sway/config' } - - { src: 'foot.ini', dest: 'foot/foot.ini' } - - { src: 'waybar/waybar.config', dest: 'waybar/config' } - - { src: 'waybar/style.css', dest: 'waybar/style.css' } - - { src: 'mako.config', dest: 'mako/config' } - - { src: 'river/init', dest: 'river/init' } - - - - name: Enable services - ansible.builtin.service: - name: "{{ item }}" - enabled: yes - with_items: - - ly - - iwd - - # - name: Install More apps - # kewlfft.aur.aur: - # name: visual-studio-code-bin,cargo,python,nextcloud-client - # state: latest - # use: paru - # become: yes - # become_user: aur_builder - diff --git a/inventory b/inventory deleted file mode 100644 index fb5a169..0000000 --- a/inventory +++ /dev/null @@ -1,2 +0,0 @@ -[mainhost] -localhost new_hostname=test \ No newline at end of file