[PR #6259/c9e11e5c backport][stable-6] redhat_subscription: manually unregister only when registered (#6280)

redhat_subscription: manually unregister only when registered (#6259)

When registering using D-Bus and using a version of subscription-manager
with an unimplemented 'force' option, then unregister manually the
system only if it is registered. 'subscription-manager unregister'
errors out when trying to unregister an already unregistered system.

(cherry picked from commit c9e11e5c0c)

Co-authored-by: Pino Toscano <ptoscano@redhat.com>
This commit is contained in:
patchback[bot] 2023-04-03 21:25:53 +02:00 committed by GitHub
commit 43beaf4b00
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 14 additions and 7 deletions

View file

@ -0,0 +1,4 @@
bugfixes:
- redhat_subscription - try to unregister only when already registered when ``force_register`` is specified
(https://github.com/ansible-collections/community.general/issues/6258,
https://github.com/ansible-collections/community.general/pull/6259).