add support for unregistration

Since the big refactor we have lost the ability to unregister nodes
on scale down / delete.

This patch provides the framework for this, and will be followed
by a later patch which implements unregisteration as above.

Change-Id: I02c5c18f710172b2b988067c020551e3f58c392d
This commit is contained in:
David J Peacock 2018-11-08 11:46:09 -05:00
parent b6cc4a511d
commit 5c5f7e2908
2 changed files with 13 additions and 0 deletions

View File

@ -22,3 +22,4 @@
- rhsm_register
- rhsm_repos
- rhsm_satellite
- rhsm_unregister

12
tasks/unregister.yml Normal file
View File

@ -0,0 +1,12 @@
- name: Unregister Red Hat subscription
redhat_subscription:
username: "{{ rhsm_username | default(omit) }}"
password: "{{ rhsm_password | default(omit) }}"
activationkey: "{{ rhsm_activation_key | default(omit) }}"
org_id: "{{ rhsm_org_id | default(omit) }}"
pool_ids: "{{ rhsm_pool_ids | default(omit) }}"
state: "absent"
rhsm_baseurl: "{{ rhsm_baseurl | default(omit) }}"
register: subscrition_result
tags:
- rhsm_unregister