mirror of
https://gitlab.sectorq.eu/jaydee/ansible.git
synced 2026-03-13 05:42:46 +01:00
build
This commit is contained in:
@@ -9,23 +9,35 @@
|
||||
- name: Facts
|
||||
ansible.builtin.setup:
|
||||
when: ansible_facts.architecture is not defined
|
||||
- name: Disable mirrorlist
|
||||
replace:
|
||||
|
||||
|
||||
- name: Disable mirrorlist in baseos
|
||||
ansible.builtin.ini_file:
|
||||
path: /etc/yum.repos.d/rocky.repo
|
||||
regexp: '^mirrorlist='
|
||||
replace: '#mirrorlist='
|
||||
section: baseos
|
||||
option: mirrorlist
|
||||
state: absent
|
||||
|
||||
- name: Set BaseOS baseurl
|
||||
replace:
|
||||
ansible.builtin.ini_file:
|
||||
path: /etc/yum.repos.d/rocky.repo
|
||||
regexp: '^#?baseurl=.*(BaseOS.*|baseos$)'
|
||||
replace: "baseurl={{ mirror_url }}/baseos/"
|
||||
section: baseos
|
||||
option: baseurl
|
||||
value: "{{ mirror_url }}/baseos/"
|
||||
|
||||
- name: Disable mirrorlist in appstream
|
||||
ansible.builtin.ini_file:
|
||||
path: /etc/yum.repos.d/rocky.repo
|
||||
section: appstream
|
||||
option: mirrorlist
|
||||
state: absent
|
||||
|
||||
- name: Set AppStream baseurl
|
||||
replace:
|
||||
ansible.builtin.ini_file:
|
||||
path: /etc/yum.repos.d/rocky.repo
|
||||
regexp: '^#?baseurl=.*AppStream.*'
|
||||
replace: "baseurl={{ mirror_url }}/appstream/"
|
||||
section: appstream
|
||||
option: baseurl
|
||||
value: "{{ mirror_url }}/appstream/"
|
||||
|
||||
- name: Clean DNF cache
|
||||
command: dnf clean all
|
||||
|
||||
Reference in New Issue
Block a user