Timeout on RHEL subscription check (#12115)

subscription-manager status can in some circumstances just never
terminates, with nothing indicating the problem from the Ansible
playbook log.
This makes it difficult to find the hosts misbehaving.

Add a timeout to the subscription checks (defaulting to 3 minutes). This
should be more than enough for normal circumstances while allowing
easier troubleshooting, as the hosts will be FAILED instead of the
playbook just waiting indefinitely.
This commit is contained in:
Max Gautier
2025-04-08 10:24:44 +02:00
committed by GitHub
parent 0ae9ab36ce
commit 5a6ef1dafa
2 changed files with 3 additions and 0 deletions

View File

@@ -28,6 +28,7 @@
register: rh_subscription_status
changed_when: "rh_subscription_status.rc != 0"
ignore_errors: true # noqa ignore-errors
timeout: "{{ rh_subscription_check_timeout }}"
become: true
- name: RHEL subscription Organization ID/Activation Key registration