Skip to content

Commit

Permalink
hosts.update: Reconfigure CentOS 8 repositories to vault
Browse files Browse the repository at this point in the history
CentOS Stream 8 reached EOL but our GPFS and GlusterFS environment
setup still has some dependencies which are not yet fulfilled by
CentOS Stream 9. In case of GlusterFS it lacks few gluster-ansible
related rpms whereas GPFS is not yet ready to be compiled against
newer kernel versions from CentOS Stream 9.

Therefore we stick to CentOS Stream 8 till requirements are met.
See #102
for further developments.

Signed-off-by: Anoop C S <[email protected]>
  • Loading branch information
anoopcs9 committed Jun 11, 2024
1 parent a05bd46 commit 6352ec2
Show file tree
Hide file tree
Showing 7 changed files with 40 additions and 5 deletions.
6 changes: 6 additions & 0 deletions playbooks/ansible/roles/sit.glusterfs/tasks/common/centos.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
# required for dependencies
- name: Enable GlusterFS repo
yum:
name: centos-release-gluster
state: latest
10 changes: 10 additions & 0 deletions playbooks/ansible/roles/sit.glusterfs/tasks/common/centos8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
- name: Process common OS tasks
include_tasks: centos.yml

# https://github.com/samba-in-kubernetes/sit-environment/issues/102
- name: Modify repositories to point at CentOS vault
shell: >-
find /etc/yum.repos.d/ -name '*.repo' -exec sed -i \
-e 's|^mirrorlist=|#mirrorlist=|g' \
-e 's|^#baseurl=http://mirror.centos.org|baseurl=https://vault.centos.org|g' {} \;
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
- name: Process common OS tasks
include_tasks: centos.yml
13 changes: 8 additions & 5 deletions playbooks/ansible/roles/sit.glusterfs/tasks/common/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@
- name: Enable GlusterFS nightly rpms repository
command: yum-config-manager --add-repo http://artifacts.ci.centos.org/gluster/nightly/master.repo

# required for dependencies
- name: Enable GlusterFS repo
yum:
name: centos-release-gluster
state: latest
- name: Process OS specific tasks
include_tasks: "{{ include_file }}"
vars:
prefix: "{{ role_path }}/tasks/common/"
with_first_found:
- files: "{{ [prefix] | product(config.os[site.os].includes) | map('join') | list }}"
loop_control:
loop_var: include_file
10 changes: 10 additions & 0 deletions playbooks/roles/hosts.update/tasks/centos8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
# https://github.com/samba-in-kubernetes/sit-environment/issues/102
- name: Modify repositories to point at CentOS vault
shell: >-
find /etc/yum.repos.d/ -name '*.repo' -exec sed -i \
-e 's|^mirrorlist=|#mirrorlist=|g' \
-e 's|^#baseurl=http://mirror.centos.org|baseurl=https://vault.centos.org|g' {} \;
- name: Process common OS tasks
include_tasks: centos.yml
3 changes: 3 additions & 0 deletions playbooks/roles/hosts.update/tasks/centos9.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
- name: Process common OS tasks
include_tasks: centos.yml

0 comments on commit 6352ec2

Please sign in to comment.