From ac883d33df9347908125deb1f03513d2bf8bc72b Mon Sep 17 00:00:00 2001 From: Ibrahim Mkusa Date: Tue, 3 Sep 2024 20:54:44 -0400 Subject: [PATCH] core packages installed on debian nodes(assumed) --- playbooks/setup_nodes.yml | 8 ++++++++ playbooks/update_upgrade.yml | 1 + vars/packages.yml | 22 ++++++++++++++++++++++ 3 files changed, 31 insertions(+) create mode 100644 vars/packages.yml diff --git a/playbooks/setup_nodes.yml b/playbooks/setup_nodes.yml index a78f72b..7998f06 100644 --- a/playbooks/setup_nodes.yml +++ b/playbooks/setup_nodes.yml @@ -4,6 +4,7 @@ become: true vars_files: - ../vars/secrets.yml + - ../vars/packages.yml tasks: - name: create user ansible on managed nodes user: @@ -20,3 +21,10 @@ user: ansible state: present key: "{{ lookup('file', '/home/mango/.ssh/id_rsa.pub') }}" + + - name: Core packages + apt: + name: "{{ item }}" + state: present + loop: "{{ minimal_debian_packages }}" + diff --git a/playbooks/update_upgrade.yml b/playbooks/update_upgrade.yml index 6aad2bb..d3d7738 100644 --- a/playbooks/update_upgrade.yml +++ b/playbooks/update_upgrade.yml @@ -8,6 +8,7 @@ - name: update package index on all machines ansible.builtin.apt: update_cache: yes + - name: Upgrade all packages to latest version ansible.builtin.apt: name: "*" diff --git a/vars/packages.yml b/vars/packages.yml new file mode 100644 index 0000000..da680f5 --- /dev/null +++ b/vars/packages.yml @@ -0,0 +1,22 @@ +minimal_debian_packages: + - gcc + - g++ + - git + - vim-nox + - zip + - unzip + - zsh + - ack-grep + - automake + - weechat-curses + - mutt + - ufw + - htop + - golang + - silversearcher-ag + - ncdu + - tmux + - taskwarrior + - clang + - screenfetch + - build-essential