Skip to content

Commit

Permalink
cuda fix
Browse files Browse the repository at this point in the history
  • Loading branch information
abhishek-sa1 committed Jun 6, 2024
1 parent 04a6f50 commit f6df01c
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@

- name: Configure ubuntu postscripts
ansible.builtin.include_tasks: "{{ role_path }}/../{{ control_plane_os }}/tasks/configure_postscripts.yml"
when: control_plane_os in control_plane_os_ubuntu

- name: Configure ntp postscripts
ansible.builtin.include_tasks: configure_postscripts_ntp.yml
Expand Down
17 changes: 17 additions & 0 deletions discovery/roles/postscripts/redhat/files/omnia_disable_repo
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash
################################################################################################################
# omnia_disablerepo:
# Disable omnia repository
#
#################################################################################################################
internet_repo_file_list="oracle-linux-ol8.repo uek-ol8.repo Rocky-AppStream.repo Rocky-BaseOS.repo Rocky-Extras.repo CentOS-Base.repo"

for repo_file in $internet_repo_file_list
do
if [ -f /etc/yum.repos.d/$repo_file ]; then
echo "Disabling repos $repo_file" >> /var/log/xcat/xcat.log
sed -i -e 's/enabled=1/enabled=0/' /etc/yum.repos.d/$repo_file
fi
done

dnf clean all
25 changes: 25 additions & 0 deletions discovery/roles/postscripts/redhat/tasks/configure_postscripts.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Copyright 2024 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---

- name: Copy omnia_disable_repo script to postscripts
ansible.builtin.template:
src: "{{ item.src }}"
dest: "{{ item.dest }}"
mode: "{{ item.mode }}"
with_items: "{{ omnia_disable_repo_postscripts_path }}"

- name: Configure postscripts for omnia_disable_repo
ansible.builtin.command: chdef all -p postscripts=omnia_disable_repo
changed_when: true
4 changes: 4 additions & 0 deletions discovery/roles/postscripts/redhat/vars/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,7 @@ configeth_postscripts_path: "{{ postscripts_path }}/configeth"
configeth_check_key: 'ipv4.dns "${NAMESERVERS}"'
configeth_patch_path:
- { src: "{{ role_path }}/../redhat/files/configeth.patch", dest: "/install/postscripts/configeth.patch", mode: "755" }

# Usage: configure_postscripts.yml
omnia_disable_repo_postscripts_path:
- { src: "{{ role_path }}/../redhat/files/omnia_disable_repo", dest: "/install/postscripts/omnia_disable_repo", mode: "755" }

0 comments on commit f6df01c

Please sign in to comment.