refactor ♻️: Update package installation for python3-pip and pexpect

Updated package installation to use apt instead of pip, adding optional dependency on python3-pip. Also updated the become flag for pip and expect tasks.
This commit is contained in:
2025-11-07 06:06:15 +01:00
parent a6bdc70932
commit 4c18590881

View File

@@ -9,15 +9,17 @@
ansible.builtin.debug: ansible.builtin.debug:
msg: "{{ addc_reverse_zone_name }} {{ addc_ansible_host }} {{ addc_admin_password }} {{ addc_ip_last_octet }} {{ addc_hostname }} {{ addc_auth_domain }}" msg: "{{ addc_reverse_zone_name }} {{ addc_ansible_host }} {{ addc_admin_password }} {{ addc_ip_last_octet }} {{ addc_hostname }} {{ addc_auth_domain }}"
- name: Ensure python3-pip is installed # - name: Ensure python3-pip is installed (optional)
ansible.builtin.package: # ansible.builtin.apt:
name: python3-pip # name: python3-pip
state: present # state: present
# become: true
- name: Ensure pexpect is installed - name: Ensure pexpect is installed (via apt)
ansible.builtin.pip: ansible.builtin.apt:
name: pexpect name: python3-pexpect
executable: pip3 state: present
become: true
- name: "Create the reverse DNS zone {{ addc_reverse_zone_name }}" - name: "Create the reverse DNS zone {{ addc_reverse_zone_name }}"
ansible.builtin.expect: ansible.builtin.expect: