Skip to content

Commit

Permalink
Add conditionals for Rhel9 in common role
Browse files Browse the repository at this point in the history
Signed-off-by: Aswathy S Kumar <aswathyskumar144@gmail.com>
  • Loading branch information
AswathySK committed Nov 12, 2024
1 parent b88b0d7 commit 6f9a6e3
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
failed_when: false
when:
- ansible_architecture != "s390x"
- (ansible_distribution_major_version == "9") or (ansible_distribution_major_version == "8") or (ansible_distribution_major_version == "6") or (ansible_distribution_major_version == "7")
- (ansible_distribution_major_version | int >= 6)
tags: patch_update

- name: YUM upgrade all packages
Expand Down Expand Up @@ -56,7 +56,7 @@
package: "name={{ item }} state=latest"
with_items: "{{ Additional_Build_Tools_NOT_RHEL8 }}"
when:
- (ansible_distribution_major_version != "8" and ansible_distribution_major_version != "9")
- not (ansible_distribution_major_version | int >= 8)
tags: build_tools

- name: Install additional build tools for RHEL 7
Expand Down Expand Up @@ -136,7 +136,7 @@
with_items: "{{ Java_NOT_RHEL6_PPC64 }}"
when:
- not (ansible_distribution_major_version == "6" and ansible_architecture == "ppc64")
- not (ansible_distribution_major_version == "8" or ansible_distribution_major_version == "9" )
- not (ansible_distribution_major_version | int >= 8)

- name: Install Java when RedHat 6 on ppc64
package: "name={{ item }} state=latest"
Expand All @@ -146,7 +146,7 @@
- name: Install Java when RedHat 8 and RedHat 9
package: "name={{ item }} state=latest"
with_items: "{{ Java_RHEL8 }}"
when: (ansible_distribution_major_version == "8" or ansible_distribution_major_version == "9")
when: (ansible_distribution_major_version | int >= 8)

####################
# Set default Java #
Expand Down

0 comments on commit 6f9a6e3

Please sign in to comment.