fix apt hold

This commit is contained in:
marito 2025-06-16 23:59:58 +00:00
parent ea2fd95fcf
commit dc884309d3

View File

@ -11,10 +11,13 @@
- name: "Enable phpMyAdmin"
when: utilities.phpmyadmin.enabled | default(false)
block:
- name: "Place a 'hold' on Apache packages to prevent installation"
ansible.builtin.dpkg_selections:
name: "{{ item }}"
selection: hold
- name: "Place a 'hold' on Apache packages if installed"
ansible.builtin.shell: |
if dpkg -s {{ item }} >/dev/null 2>&1; then
echo "{{ item }} hold" | dpkg --set-selections
fi
args:
executable: /bin/bash
loop: "{{ apache_packages }}"
- name: "Install phpMyAdmin from APT repository"