Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: allows Rocky Linux to install #149

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dcmbrown
Copy link

Problem:
Was trying to install java 11 openjdk on an AWS Rocky Linux 9 VM and it was skipping the actual installation include constantly.

notes:

  • ansible version 2.9.27 (because it's LTS version for RedHat of course)
  • python 3.12

Investigation:
Rocky Linux 9 appears to not identify as the OS family "RedHat" all of the time for some reason, possibly identifying dependent on how it was called.

  1. via an ansible -i ec2.py prod.yml
TASK [debug ansible OS family] ***********************************************************************************
ok: [some.ip.numbers.here] => {
    "msg": "Rocky"
}

TASK [debug ansible distribution] **********************************************************************************
ok: [same.ip.numbers.here] => {
    "msg": "Rocky"
}

along with debugging at -vvvvv

ansible_distribution": "Rocky", "ansible_distribution_release": "Blue Onyx", "ansible_distribution_version": "9.4", "ansible_distribution_major_version": "9", "ansible_distribution_file_path": "/etc/redhat-release", "ansible_distribution_file_variety": "RedHat", "ansible_distribution_file_parsed": true, "ansible_os_family": "Rocky",
  1. however via ansible localhost -m ansible.builtin.setup on the server:
...
        "ansible_distribution": "Rocky",
        "ansible_distribution_file_parsed": true,
        "ansible_distribution_file_path": "/etc/redhat-release",
        "ansible_distribution_file_variety": "RedHat",
        "ansible_distribution_major_version": "9",
        "ansible_distribution_release": "Blue Onyx",
        "ansible_distribution_version": "9.4",
...
        "ansible_nodename": "<sshh secret>",
        "ansible_os_family": "RedHat",
...

Took a look at an Azure Rocky Linux 9 machine and it does the same thing.

Fix:
Maybe this is a 2.9.x problem only but I applied the ansible_distribution array to the ansible_os_family section as well to fix the issue in order to get the setup-RedHat.yml include for Java to install.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant