Browse Source

Merge pull request #9888 from e-minguez/unregister_ak_orgid

Add support for ak/orgid at uninstall/scale
OpenShift Merge Robot 6 years ago
parent
commit
f396fd4354

+ 1 - 2
playbooks/openstack/openshift-cluster/master-scaleup.yml

@@ -61,8 +61,7 @@
       name: rhel_subscribe
     when:
     - ansible_distribution == "RedHat"
-    - rhsub_user is defined
-    - rhsub_pass is defined
+    - (rhsub_user is defined and rhsub_pass is defined) or (rhsub_ak is defined and rhsub_orgid is defined)
 
 - name: Configure the new OpenStack nodes
   import_playbook: configure-new-nodes.yml

+ 1 - 2
playbooks/openstack/openshift-cluster/node-scaleup.yml

@@ -61,8 +61,7 @@
       name: rhel_subscribe
     when:
     - ansible_distribution == "RedHat"
-    - rhsub_user is defined
-    - rhsub_pass is defined
+    - (rhsub_user is defined and rhsub_pass is defined) or (rhsub_ak is defined and rhsub_orgid is defined)
 
 - name: Configure the new OpenStack nodes
   import_playbook: configure-new-nodes.yml

+ 1 - 2
playbooks/openstack/openshift-cluster/uninstall.yml

@@ -15,8 +15,7 @@
       name: rhel_unsubscribe
     when:
     - ansible_distribution == "RedHat"
-    - rhsub_user is defined
-    - rhsub_pass is defined
+    - (rhsub_user is defined and rhsub_pass is defined) or (rhsub_ak is defined and rhsub_orgid is defined)
 
 - name: Clean DNS entries
   hosts: localhost

+ 4 - 1
playbooks/openstack/sample-inventory/group_vars/all.yml

@@ -152,9 +152,12 @@ openshift_openstack_pool_start: "192.168.99.3"
 # The ending IP address for the OpenStack subnet allocation pool.
 openshift_openstack_pool_end: "192.168.99.254"
 
-## Red Hat subscription:
+## Red Hat subscription using user/password
 #rhsub_user: '<username>'
 #rhsub_pass: '<password>'
+# Or if using activation key:
+#rhsub_ak: '<ak>'
+#rhsub_orgid: '<orgid>'
 #rhsub_pool: '<pool name>'