Uploaded image for project: 'Satellite'
  1. Satellite
  2. SAT-23302

Support Satellite Ansible Collection running on Python 3.12

    • None
    • None
    • None
    • None
    • No

      Description of problem:
      Ansible will start using Python 3.12 in EL8 when it's updated to 2.16.3-2[1]

      We need to ensure our collection pulls in the right dependencies for that Python version, as otherwise things might break.

      [1] https://kojihub.stream.centos.org/koji/buildinfo?buildID=50584

      Version-Release number of selected component (if applicable):
      Any supported Satellite versions on EL8

      How reproducible:
      100%

      Steps to Reproduce:
      1. install ansible-core 2.16.3-2 (or newer)
      2. run an Ansible role via Satellite

      Actual results:
      Execution works, but there is no report in Satellite

      Expected results:
      report works as it did before

      Additional info:
      Previously: BZ#2170034
      Upstream: https://github.com/theforeman/foreman-packaging/pull/10428

            [SAT-23302] Support Satellite Ansible Collection running on Python 3.12

            Errata Tool added a comment -

            Since the problem described in this issue should be resolved in a recent advisory, it has been closed.

            For information on the advisory (Critical: Satellite 6.16.0 release), and where to find the updated files, follow the link below.

            If the solution does not work for you, open a new bug report.
            https://access.redhat.com/errata/RHSA-2024:8906

            Errata Tool added a comment - Since the problem described in this issue should be resolved in a recent advisory, it has been closed. For information on the advisory (Critical: Satellite 6.16.0 release), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2024:8906

            Eric Helms added a comment -

            This BZ has been automatically migrated to the issues.redhat.com Red Hat Issue Tracker. All future work related to this report will be managed there.

            Due to differences in account names between systems, some fields were not replicated. Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information.

            To find the migrated issue, look in the "Links" section for a direct link to the new issue location. The issue key will have an icon of 2 footprints next to it, and begin with "SAT-" followed by an integer. You can also find this issue by visiting https://issues.redhat.com/issues/?jql= and searching the "Bugzilla Bug" field for this BZ's number, e.g. a search like:

            "Bugzilla Bug" = 1234567

            In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues@redhat.com. You can also visit https://access.redhat.com/articles/7032570 for general account information.

            Eric Helms added a comment - This BZ has been automatically migrated to the issues.redhat.com Red Hat Issue Tracker. All future work related to this report will be managed there. Due to differences in account names between systems, some fields were not replicated. Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information. To find the migrated issue, look in the "Links" section for a direct link to the new issue location. The issue key will have an icon of 2 footprints next to it, and begin with "SAT-" followed by an integer. You can also find this issue by visiting https://issues.redhat.com/issues/?jql= and searching the "Bugzilla Bug" field for this BZ's number, e.g. a search like: "Bugzilla Bug" = 1234567 In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues@redhat.com. You can also visit https://access.redhat.com/articles/7032570 for general account information.

            Lukas Pramuk added a comment - - edited

            VERIFIED.

            @Satellite Stream Snap49
            ansible-collection-redhat-satellite-4.0.0-2.el8sat.noarch

            A) by this simple reproducer:

            1. rpm -qR ansible-collection-redhat-satellite | grep core
              (ansible >= 2.9 or ansible-core)
              (python3.11-pyyaml if (ansible-core >= 2.14.2-3 and ansible-core < 2.16.3-2))
              (python3.11-requests if (ansible-core >= 2.14.2-3 and ansible-core < 2.16.3-2))
              (python3.12-pyyaml if ansible-core >= 2.16.3-2)
              (python3.12-requests if ansible-core >= 2.16.3-2)
              (python38-pyyaml if ansible-core < 2.13)
              (python38-requests if ansible-core < 2.13)
              (python39-pyyaml if (ansible-core >= 2.13 and ansible-core < 2.14.2-3))
              (python39-requests if (ansible-core >= 2.13 and ansible-core < 2.14.2-3))
            1. rpm -qR rubygem-smart_proxy_ansible | grep runner
              ansible-runner >= 2

            >>> requirements are RHEL8.10 ready

            B) by running Satellite in-place upgrade of RHEL to RHEL-8.10 (using internal RHEL candidate repo)

            1. dnf repolist
              ...
              repo id repo name
              AppStream AppStream
              BaseOS BaseOS
              Satellite_Engineering_Satellite_stream_Composes_Satellite_stream_RHEL8 Satellite Stream RHEL8
              Satellite_Engineering_Satellite_stream_Composes_Satellite_Maintenance_stream_RHEL8 Satellite Maintenance Stream RHEL8
            1. satellite-maintain upgrade run --target-version 6.16.z -w repositories-setup,repositories-validate -y
              ...
              Update package(s) : [OK]
              --------------------------------------------------------------------------------
              Procedures::Installer::Upgrade: [OK]
              --------------------------------------------------------------------------------
              Execute upgrade:run rake task: [OK]
              --------------------------------------------------------------------------------
              ...
              --------------------------------------------------------------------------------
              Upgrade finished.

            >>> there are now no dependency issues on RHEL-8.10 as in-place upgrade to RHEL-8.10 is successful

            C) by running Ansible REX at Satellite on RHEL-8.10

            1. jobid=$(hammer --csv host ansible-roles play --name $(hostname) | awk -F, 'NR>1 {print$2}

              ')

            1. hammer job-invocation output --id $jobid --host $(hostname)
              [DEPRECATION WARNING]: ANSIBLE_COLLECTIONS_PATHS option, does not fit var
              naming standard, use the singular form ANSIBLE_COLLECTIONS_PATH instead. This
              feature will be removed from ansible-core in version 2.19. Deprecation warnings
              can be disabled by setting deprecation_warnings=False in ansible.cfg.
              ...

            PLAY RECAP *********************************************************************
            satellite.example.com : ok=6 changed=1 unreachable=0 failed=0 skipped=8 rescued=0 ignored=0
            Exit status: 0

            1. hammer config-report list --search host=$(hostname),applied=1
              --|----------------------------------------------|-------------------|-------|-------|---------|------|----------------|-------|-------
              ID | HOST | LAST REPORT | ORIGIN | APPLIED | RESTARTED | FAILED | RESTART FAILURES | SKIPPED | PENDING
              --|----------------------------------------------|-------------------|-------|-------|---------|------|----------------|-------|-------
              1 | satellite.example.com | 2024/03/01 11:38:07 | Ansible | 1 | 0 | 0 | 0 | 8 | 0
              --|----------------------------------------------|-------------------|-------|-------|---------|------|----------------|-------|-------

            >>> REX action and namely 'redhat.satellite.foreman' callback finished successfully

            Lukas Pramuk added a comment - - edited VERIFIED. @Satellite Stream Snap49 ansible-collection-redhat-satellite-4.0.0-2.el8sat.noarch A) by this simple reproducer: rpm -qR ansible-collection-redhat-satellite | grep core (ansible >= 2.9 or ansible-core) (python3.11-pyyaml if (ansible-core >= 2.14.2-3 and ansible-core < 2.16.3-2)) (python3.11-requests if (ansible-core >= 2.14.2-3 and ansible-core < 2.16.3-2)) (python3.12-pyyaml if ansible-core >= 2.16.3-2) (python3.12-requests if ansible-core >= 2.16.3-2) (python38-pyyaml if ansible-core < 2.13) (python38-requests if ansible-core < 2.13) (python39-pyyaml if (ansible-core >= 2.13 and ansible-core < 2.14.2-3)) (python39-requests if (ansible-core >= 2.13 and ansible-core < 2.14.2-3)) rpm -qR rubygem-smart_proxy_ansible | grep runner ansible-runner >= 2 >>> requirements are RHEL8.10 ready B) by running Satellite in-place upgrade of RHEL to RHEL-8.10 (using internal RHEL candidate repo) dnf repolist ... repo id repo name AppStream AppStream BaseOS BaseOS Satellite_Engineering_Satellite_stream_Composes_Satellite_stream_RHEL8 Satellite Stream RHEL8 Satellite_Engineering_Satellite_stream_Composes_Satellite_Maintenance_stream_RHEL8 Satellite Maintenance Stream RHEL8 satellite-maintain upgrade run --target-version 6.16.z -w repositories-setup,repositories-validate -y ... Update package(s) : [OK] -------------------------------------------------------------------------------- Procedures::Installer::Upgrade: [OK] -------------------------------------------------------------------------------- Execute upgrade:run rake task: [OK] -------------------------------------------------------------------------------- ... -------------------------------------------------------------------------------- Upgrade finished. >>> there are now no dependency issues on RHEL-8.10 as in-place upgrade to RHEL-8.10 is successful C) by running Ansible REX at Satellite on RHEL-8.10 jobid=$(hammer --csv host ansible-roles play --name $(hostname) | awk -F, 'NR>1 {print$2} ') hammer job-invocation output --id $jobid --host $(hostname) [DEPRECATION WARNING] : ANSIBLE_COLLECTIONS_PATHS option, does not fit var naming standard, use the singular form ANSIBLE_COLLECTIONS_PATH instead. This feature will be removed from ansible-core in version 2.19. Deprecation warnings can be disabled by setting deprecation_warnings=False in ansible.cfg. ... PLAY RECAP ********************************************************************* satellite.example.com : ok=6 changed=1 unreachable=0 failed=0 skipped=8 rescued=0 ignored=0 Exit status: 0 hammer config-report list --search host=$(hostname),applied=1 -- | ---------------------------------------------- | ------------------- | ------- | ------- | --------- | ------ | ---------------- | ------- | ------- ID | HOST | LAST REPORT | ORIGIN | APPLIED | RESTARTED | FAILED | RESTART FAILURES | SKIPPED | PENDING -- | ---------------------------------------------- | ------------------- | ------- | ------- | --------- | ------ | ---------------- | ------- | ------- 1 | satellite.example.com | 2024/03/01 11:38:07 | Ansible | 1 | 0 | 0 | 0 | 8 | 0 -- | ---------------------------------------------- | ------------------- | ------- | ------- | --------- | ------ | ---------------- | ------- | ------- >>> REX action and namely 'redhat.satellite.foreman' callback finished successfully

              rhn-support-osousa Odilon Sousa
              egolov@redhat.com Evgeni Golov
              RH Bugzilla Integration RH Bugzilla Integration
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: