mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
[redhat_subscription]: fixed force option. (#20667)
`force` option is not unique for non-activationkey registrations and it should be parsed separately; it is possible to register host with activation key and force such process.
This commit is contained in:
parent
47892a0034
commit
9d8c1923ab
1 changed files with 3 additions and 2 deletions
|
@ -292,6 +292,9 @@ class Rhsm(RegistrationBase):
|
|||
args = [SUBMAN_CMD, 'register']
|
||||
|
||||
# Generate command arguments
|
||||
if force_register:
|
||||
args.extend(['--force'])
|
||||
|
||||
if activationkey:
|
||||
args.extend(['--activationkey', activationkey])
|
||||
args.extend(['--org', org_id])
|
||||
|
@ -308,8 +311,6 @@ class Rhsm(RegistrationBase):
|
|||
args.extend(['--name', consumer_name])
|
||||
if consumer_id:
|
||||
args.extend(['--consumerid', consumer_id])
|
||||
if force_register:
|
||||
args.extend(['--force'])
|
||||
if environment:
|
||||
args.extend(['--environment', environment])
|
||||
|
||||
|
|
Loading…
Reference in a new issue