Browse Source

Rework provisioners vars to support different prefix/version for Origin/OSE

Vadim Rutkovsky 7 years ago
parent
commit
a689ff21d5

+ 8 - 2
roles/openshift_provisioners/defaults/main.yaml

@@ -1,7 +1,5 @@
 ---
 openshift_provisioners_install_provisioners: True
-openshift_provisioners_image_prefix: docker.io/openshift/origin-
-openshift_provisioners_image_version: latest
 
 openshift_provisioners_efs: False
 openshift_provisioners_efs_path: /persistentvolumes
@@ -10,3 +8,11 @@ openshift_provisioners_efs_nodeselector: ""
 openshift_provisioners_efs_supplementalgroup: '65534'
 
 openshift_provisioners_project: openshift-infra
+
+openshift_provisioners_image_prefix_dict:
+  origin: "docker.io/openshift/origin-"
+  openshift-enterprise: "registry.access.redhat.com/openshift3/ose-"
+
+openshift_provisioners_image_version_dict:
+  origin: "latest"
+  openshift-enterprise: "{{ openshift_image_tag }}"

+ 5 - 0
roles/openshift_provisioners/tasks/main.yaml

@@ -12,6 +12,11 @@
   check_mode: no
   tags: provisioners_init
 
+- name: Set eventrouter image facts
+  set_fact:
+    openshift_provisioners_image_prefix: "{{ openshift_provisioners_image_prefix | default(openshift_provisioners_image_prefix_dict[openshift_deployment_type]) }}"
+    openshift_provisioners_image_version: "{{ openshift_provisioners_image_version | default(openshift_provisioners_image_version_dict[openshift_deployment_type]) }}"
+
 - include_tasks: install_provisioners.yaml
   when: openshift_provisioners_install_provisioners | default(false) | bool