initial commit
This commit is contained in:
commit
e37fce10f3
2
ansible.cfg
Executable file
2
ansible.cfg
Executable file
@ -0,0 +1,2 @@
|
||||
[defaults]
|
||||
inventory = inventory
|
5
inventory
Executable file
5
inventory
Executable file
@ -0,0 +1,5 @@
|
||||
servers:
|
||||
hosts:
|
||||
debian-pods:
|
||||
ansible_host: 192.168.0.28
|
||||
ansible_user: admin
|
15
main.yml
Executable file
15
main.yml
Executable file
@ -0,0 +1,15 @@
|
||||
---
|
||||
|
||||
- name: configure host
|
||||
hosts: all
|
||||
|
||||
vars_files:
|
||||
- vars
|
||||
- vault.yml
|
||||
|
||||
tasks:
|
||||
- import_tasks: tasks/setup.yml
|
||||
tags: ['setup']
|
||||
|
||||
- import_tasks: tasks/nvidia.yml
|
||||
tags: ['nvidia']
|
20
tasks/nvidia.yml
Executable file
20
tasks/nvidia.yml
Executable file
@ -0,0 +1,20 @@
|
||||
- name: Gather current kernel version
|
||||
ansible.builtin.shell: uname -r
|
||||
register: kernel_version
|
||||
|
||||
- name: install Nvidia driver
|
||||
become: true
|
||||
ansible.builtin.apt:
|
||||
pkg:
|
||||
- nvidia-driver
|
||||
- firmware-misc-nonfree
|
||||
- nvidia-driver-libs:i386
|
||||
state: present
|
||||
update_cache: true
|
||||
register: updated_driver
|
||||
|
||||
- name: Unconditionally reboot the machine with all defaults
|
||||
become: true
|
||||
ansible.builtin.reboot:
|
||||
when: updated_driver.changed
|
||||
|
184
tasks/setup.yml
Executable file
184
tasks/setup.yml
Executable file
@ -0,0 +1,184 @@
|
||||
---
|
||||
|
||||
- name: add contrib and nonfree
|
||||
become: true
|
||||
ansible.builtin.apt_repository:
|
||||
repo: deb http://deb.debian.org/debian {{ ansible_distribution_release }} main contrib non-free non-free-firmware
|
||||
state: present
|
||||
|
||||
- name: update apt and install gui apps
|
||||
become: true
|
||||
ansible.builtin.apt:
|
||||
pkg:
|
||||
- audacity
|
||||
- blender
|
||||
- cura
|
||||
- firefox-esr
|
||||
- gimp
|
||||
- inkscape
|
||||
- kiwix
|
||||
- libreoffice
|
||||
- libreoffice-gnome
|
||||
- monero
|
||||
- mpv
|
||||
- obs-studio
|
||||
- retroarch
|
||||
- thunderbird
|
||||
- torbrowser-launcher
|
||||
- virt-manager
|
||||
- wireshark
|
||||
#gnome
|
||||
- gnome-core
|
||||
- gnome-tweaks
|
||||
- gnome-shell-extension-dashtodock
|
||||
state: latest
|
||||
update_cache: true
|
||||
- name: install terminal apps
|
||||
become: true
|
||||
ansible.builtin.apt:
|
||||
pkg:
|
||||
- ansible
|
||||
- cabextract
|
||||
- cataclysm-dda-curses
|
||||
- cifs-utils
|
||||
- cmatrix
|
||||
- cups
|
||||
- curl
|
||||
- exiftool
|
||||
- ffmpeg
|
||||
- fzf
|
||||
- git
|
||||
- gnupg
|
||||
- htop
|
||||
- iperf3
|
||||
- lm-sensors
|
||||
- mediainfo
|
||||
- neofetch
|
||||
- neovim
|
||||
- nfs-common
|
||||
- nmap
|
||||
- pip
|
||||
- qrencode
|
||||
- smartmontools
|
||||
- telnet
|
||||
- tmux
|
||||
- ttf-mscorefonts-installer
|
||||
- unzip
|
||||
- wget
|
||||
- wine
|
||||
- xxd
|
||||
- yt-dlp
|
||||
|
||||
- name: install steam
|
||||
become: true
|
||||
block:
|
||||
- name: add i386 architecture
|
||||
ansible.builtin.shell:
|
||||
cmd:
|
||||
dpkg --add-architecture i386
|
||||
- name: install steam-installer
|
||||
ansible.builtin.apt:
|
||||
pkg:
|
||||
- steam-installer
|
||||
- mesa-vulkan-drivers
|
||||
- libglx-mesa0:i386
|
||||
- mesa-vulkan-drivers:i386
|
||||
- libgl1-mesa-dri:i386
|
||||
update_cache: true
|
||||
|
||||
- name: install signal
|
||||
become: true
|
||||
block:
|
||||
- name: get signal key
|
||||
ansible.builtin.get_url:
|
||||
url: https://updates.signal.org/desktop/apt/keys.asc
|
||||
dest: /etc/apt/keyrings/signal.asc
|
||||
- name: install signal key
|
||||
ansible.builtin.apt_repository:
|
||||
repo: "deb [arch=amd64 signed-by=/etc/apt/keyrings/signal.asc] https://updates.signal.org/desktop/apt xenial main"
|
||||
state: present
|
||||
- name: install signal package
|
||||
ansible.builtin.apt:
|
||||
pkg:
|
||||
- signal-desktop
|
||||
update_cache: true
|
||||
|
||||
- name: install discord
|
||||
become: true
|
||||
block:
|
||||
- name: get discord.deb
|
||||
ansible.builtin.get_url:
|
||||
url: https://discord.com/api/download?platform=linux&format=deb
|
||||
dest: /tmp/discord.deb
|
||||
- name: install discord.deb
|
||||
ansible.builtin.apt:
|
||||
deb: /tmp/discord.deb
|
||||
|
||||
- name: install bitwarden
|
||||
block:
|
||||
- name: create ~/admin/apps
|
||||
ansible.builtin.file:
|
||||
path: /home/admin/apps
|
||||
state: directory
|
||||
- name: download bitwarden appimage
|
||||
ansible.builtin.get_url:
|
||||
url: https://vault.bitwarden.com/download/?app=desktop&platform=linux
|
||||
dest: /home/admin/apps/bitwarden.AppImage
|
||||
- name: permissions
|
||||
ansible.builtin.file:
|
||||
path: /home/admin/apps/bitwarden.AppImage
|
||||
owner: admin
|
||||
group: admin
|
||||
mode: '0766'
|
||||
|
||||
- name: install joplin
|
||||
ansible.builtin.shell:
|
||||
cmd: wget -O - https://raw.githubusercontent.com/laurent22/joplin/dev/Joplin_install_and_update.sh | bash
|
||||
|
||||
#- name: install ollama
|
||||
# ansible.builtin.shell:
|
||||
# cmd: curl -fsSL https://ollama.com/install.sh | sh
|
||||
|
||||
- name: install umu-launcher
|
||||
block:
|
||||
- name: install python3-umu-launcher
|
||||
become: true
|
||||
ansible.builtin.apt:
|
||||
deb: https://github.com/Open-Wine-Components/umu-launcher/releases/download/1.2.5/python3-umu-launcher_1.2.5-1_amd64_debian-12.deb
|
||||
- name: install umu-launcher
|
||||
become: true
|
||||
ansible.builtin.apt:
|
||||
deb: https://github.com/Open-Wine-Components/umu-launcher/releases/download/1.2.5/umu-launcher_1.2.5-1_all_debian-12.deb
|
||||
|
||||
|
||||
- name: enable workspace-indicator extension
|
||||
ansible.builtin.shell:
|
||||
cmd: gnome-extensions enable workspace-indicator@gnome-shell-extensions.gcampax.github.com
|
||||
|
||||
- name: increase map count for games
|
||||
become: true
|
||||
ansible.posix.sysctl:
|
||||
name: vm.max_map_count
|
||||
value: 16777216
|
||||
sysctl_file: /etc/sysctl.d/games.conf
|
||||
|
||||
- name: gnome settings
|
||||
ansible.builtin.shell:
|
||||
cmd: |
|
||||
gsettings set org.gnome.desktop.interface gtk-theme 'Adwaita-dark'
|
||||
gsettings set org.gnome.desktop.interface color-scheme prefer-dark
|
||||
gsettings set org.gnome.desktop.interface enable-hot-corners false
|
||||
gnome-extensions enable dash-to-dock@micxgx.gmail.com
|
||||
gsettings set org.gnome.desktop.wm.preferences button-layout ":minimize,maximize,close"
|
||||
gsettings set org.gnome.desktop.peripherals.mouse accel-profile 'flat'
|
||||
gsettings set org.gnome.shell favorite-apps "['org.gnome.Nautilus.desktop', 'firefox-esr.desktop', 'thunderbird.desktop', 'appimagekit-joplin.desktop', 'signal-desktop.desktop', 'discord.desktop', 'steam.desktop', 'org.gnome.Settings.desktop', 'org.gnome.Terminal.desktop']"
|
||||
gsettings set org.gnome.nautilus.preferences default-folder-viewer list-view
|
||||
gsettings set org.gnome.nautilus.list-view default-zoom-level 'small'
|
||||
gsettings set org.gnome.shell.extensions.dash-to-dock apply-custom-theme true
|
||||
gsettings set org.gnome.shell.extensions.dash-to-dock dock-fixed true
|
||||
gsettings set org.gnome.shell.extensions.dash-to-dock multi-monitor true
|
||||
gsettings set org.gnome.shell.extensions.dash-to-dock show-mounts false
|
||||
gsettings set org.gnome.shell.extensions.dash-to-dock show-show-apps-button false
|
||||
gsettings set org.gnome.shell.extensions.dash-to-dock click-action 'focus-minimize-or-previews'
|
||||
#gsettings set org.gnome.shell.keybindings show-screenshot-ui '<Shift><Super>s'
|
||||
|
17
tasks/steam.yml
Normal file
17
tasks/steam.yml
Normal file
@ -0,0 +1,17 @@
|
||||
- name: add i386 arch
|
||||
become: true
|
||||
ansible.builtin.shell:
|
||||
cmd: dpkg --add-architecture i386
|
||||
|
||||
- name: update apt and install gui apps
|
||||
become: true
|
||||
ansible.builtin.apt:
|
||||
pkg:
|
||||
- steam-installer
|
||||
- mesa-vulkan-drivers
|
||||
- libglx-mesa0:i386
|
||||
- mesa-vulkan-drivers:i386
|
||||
- libgl1-mesa-dri:i386
|
||||
state: latest
|
||||
update_cache: true
|
||||
|
6
vault.yml
Normal file
6
vault.yml
Normal file
@ -0,0 +1,6 @@
|
||||
$ANSIBLE_VAULT;1.1;AES256
|
||||
32396236343539346435343962343264363839303063663164333233373935343663316530633232
|
||||
6263636535353531643935633931623739643231633532340a303165613032363763663531643732
|
||||
34386631643739646332383931623062626136313263626331303732656661616666306334373763
|
||||
6331363261326338360a356437346263383565363464663333363163333437316233313932383632
|
||||
66613461383634393861653531613131343230623263663863303963633063613562
|
Loading…
x
Reference in New Issue
Block a user