Rename some roles to make ansible-lint happy.

This commit is contained in:
Andreas B. Mundt 2022-06-12 14:27:44 +02:00 committed by Andreas B. Mundt
parent 4d791a65f1
commit 1db0b6ec31
75 changed files with 29 additions and 29 deletions

View file

@ -0,0 +1,40 @@
- name: install apt-cacher-ng package
apt:
name: apt-cacher-ng
state: latest # noqa package-latest
- name: enable apt-cacher-ng for localhost
copy:
src: apt.conf
dest: /etc/apt/apt.conf
force: false
mode: 0644
notify: "start apt-cacher-ng"
when: not run_in_installer|default(false)|bool ## do not enable apt-cacher during installation
- name: check if preseeded installer is available
stat: path={{ tftp_root }}/d-i/{{ di_dist }}/preseed.cfg
register: preseedcfg
- name: enable apt-cacher-ng for install-clients
replace:
dest: "{{ tftp_root }}/d-i/{{ di_dist }}/preseed.cfg"
regexp: '^d-i mirror/http/proxy string$'
replace: 'd-i mirror/http/proxy string http://{{ ansible_hostname }}:3142/'
when: preseedcfg.stat.exists
- name: allow apt-cacher-ng service in firewalld
firewalld:
zone: internal
port: 3142/tcp
permanent: true
immediate: true
state: enabled
when: not run_in_installer|default(false)|bool
- name: allow apt-cacher-ng service in firewalld, offline
command: "firewall-offline-cmd --zone=internal --add-port=3142/tcp"
when: run_in_installer|default(false)|bool
- name: flush handler to make apt-cacher available
meta: flush_handlers