infra-ansible icon indicating copy to clipboard operation
infra-ansible copied to clipboard

rhsm role will hang forever if rhsm_password or rhsm_user isn't defined when unregistered

Open ericzolf opened this issue 5 years ago • 0 comments

If the host isn't yet registered (or has been forcefully de-registered) and either rhsm_password or rhsm_user is missing, subscription-manager will wait for input of the missing value(s) and the playbook will stay stuck.

I am the opinion that this case should be checked and lead to a failed state, but perhaps I'm missing a valid use case.

Proposed approach would be:

  1. analyse output of subscription-manager status to validate if the system is already registered or not.
  2. if the system isn't registered and one of rhsm_password or rhsm_user is undefined/empty, then fail.

ericzolf avatar Jan 21 '19 12:01 ericzolf