File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ ---
2+ minor_changes :
3+ - Use vault repositories for CentOS 7.
4+
5+ ...
Original file line number Diff line number Diff line change 11---
22# defaults file for common
33
4+ common_centos7_repos :
5+ - CentOS-Base.repo
6+ - CentOS-CR.repo
7+ - CentOS-Debuginfo.repo
8+ - CentOS-fasttrack.repo
9+ - CentOS-Media.repo
10+ - CentOS-Sources.repo
11+ - CentOS-Vault.repo
12+ - CentOS-x86_64-kernel.repo
13+
414common_centos8_repos :
515 - CentOS-Linux-AppStream.repo
616 - CentOS-Linux-BaseOS.repo
Original file line number Diff line number Diff line change 77 - ansible_distribution not in common_supported_distribution
88 - ansible_distribution_major_version in common_supported_major_version
99
10+ - name : Patch repositories if dealing with CentOS 7.
11+ block :
12+ - name : Comment mirrorlist in all repos.
13+ ansible.builtin.replace :
14+ path : /etc/yum.repos.d/{{ item }}
15+ regexp : ^mirrorlist
16+ replace : " #mirrorlist"
17+ loop : " {{ common_centos7_repos }}"
18+ when : ansible_distribution == 'CentOS' and ansible_distribution_major_version | int == 7
19+
20+ - name : Switch repo to vault.centos.org.
21+ ansible.builtin.replace :
22+ path : /etc/yum.repos.d/{{ item }}
23+ regexp : " #baseurl=http://mirror.centos.org"
24+ replace : baseurl=https://vault.centos.org
25+ loop : " {{ common_centos7_repos }}"
26+ when : ansible_distribution == 'CentOS' and ansible_distribution_major_version | int == 7
27+
1028- name : Patch repositories if dealing with CentOS 8.
1129 block :
1230 - name : Comment mirrorlist in all repos.
You can’t perform that action at this time.
0 commit comments