Skip to content
Snippets Groups Projects
Unverified Commit bcf69591 authored by Florian Ruynat's avatar Florian Ruynat Committed by GitHub
Browse files

Fix Oracle yum disabled repository file after EPEL install (#7639)

parent 23cd1d41
Branches
Tags v2.16.0
No related merge requests found
...@@ -41,6 +41,15 @@ ...@@ -41,6 +41,15 @@
- '''ID="ol"'' in os_release.stdout_lines' - '''ID="ol"'' in os_release.stdout_lines'
- (ansible_distribution_version | float) < 7.6 - (ansible_distribution_version | float) < 7.6
- name: Install EPEL for Oracle Linux repo package
package:
name: "oracle-epel-release-el{{ ansible_distribution_major_version }}"
state: present
when:
- use_oracle_public_repo|default(true)
- '''ID="ol"'' in os_release.stdout_lines'
- (ansible_distribution_version | float) >= 7.6
- name: Enable Oracle Linux repo - name: Enable Oracle Linux repo
ini_file: ini_file:
dest: "/etc/yum.repos.d/oracle-linux-ol{{ ansible_distribution_major_version }}.repo" dest: "/etc/yum.repos.d/oracle-linux-ol{{ ansible_distribution_major_version }}.repo"
...@@ -48,6 +57,7 @@ ...@@ -48,6 +57,7 @@
option: "{{ item.option }}" option: "{{ item.option }}"
value: "{{ item.value }}" value: "{{ item.value }}"
with_items: with_items:
- { option: "name", value: "ol{{ ansible_distribution_major_version }}_addons" }
- { option: "enabled", value: "1" } - { option: "enabled", value: "1" }
- { option: "baseurl", value: "http://yum.oracle.com/repo/OracleLinux/OL{{ ansible_distribution_major_version }}/addons/x86_64/" } - { option: "baseurl", value: "http://yum.oracle.com/repo/OracleLinux/OL{{ ansible_distribution_major_version }}/addons/x86_64/" }
when: when:
...@@ -55,15 +65,6 @@ ...@@ -55,15 +65,6 @@
- '''ID="ol"'' in os_release.stdout_lines' - '''ID="ol"'' in os_release.stdout_lines'
- (ansible_distribution_version | float) >= 7.6 - (ansible_distribution_version | float) >= 7.6
- name: Install EPEL for Oracle Linux repo package
package:
name: "oracle-epel-release-el{{ ansible_distribution_major_version }}"
state: present
when:
- use_oracle_public_repo|default(true)
- '''ID="ol"'' in os_release.stdout_lines'
- (ansible_distribution_version | float) >= 7.6
# CentOS ships with python installed # CentOS ships with python installed
- name: Check presence of fastestmirror.conf - name: Check presence of fastestmirror.conf
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment