make the packages role more generic

This commit is contained in:
Matthew Stobbs
2025-01-18 09:24:11 -07:00
parent 3d466e64c7
commit 333ee4c3f5
112 changed files with 1610 additions and 3 deletions

View File

@@ -0,0 +1,33 @@
---
- name: full system upgrade if enabled
ansible.builtin.dnf:
name: "*"
state: latest
when: full_upgrade
become: true
tags:
- upgrade
- packages
- asroot
- RedHat
- name: install packages from system package manager
ansible.builtin.dnf:
name: "{{ syspkgs | unique }}"
state: "{{ install_state }}"
when: syspkgs|length > 0
become: true
tags:
- packages
- asroot
- os
- name: install packages from outside system
ansible.builtin.include_tasks:
file: "{{ altpkg }}"
loop: "{{ altpkgs }}"
loop_control:
loop_var: altpkg
tags:
- packages
- altinstall