diff options
author | Michael Gugino <gugino.michael@yahoo.com> | 2017-12-08 09:52:15 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-12-08 09:52:15 -0500 |
commit | 0f98871d0f4cf39eded2fcd6041fcea4f83bbed6 (patch) | |
tree | dd4269d8cd6d4f8beb4becea8a883716e6081f13 /roles/openshift_version | |
parent | 2af8419bab887c8552337333023ce357b1a18bc0 (diff) | |
parent | eb6b20fc9183cc2aae424c72efd1191b99110a93 (diff) | |
download | openshift-0f98871d0f4cf39eded2fcd6041fcea4f83bbed6.tar.gz openshift-0f98871d0f4cf39eded2fcd6041fcea4f83bbed6.tar.bz2 openshift-0f98871d0f4cf39eded2fcd6041fcea4f83bbed6.tar.xz openshift-0f98871d0f4cf39eded2fcd6041fcea4f83bbed6.zip |
Merge pull request #6278 from mgugino-upstream-stage/service_type
Remove openshift.common.service_type
Diffstat (limited to 'roles/openshift_version')
-rw-r--r-- | roles/openshift_version/defaults/main.yml | 6 | ||||
-rw-r--r-- | roles/openshift_version/tasks/main.yml | 8 | ||||
-rw-r--r-- | roles/openshift_version/tasks/set_version_rpm.yml | 6 |
3 files changed, 13 insertions, 7 deletions
diff --git a/roles/openshift_version/defaults/main.yml b/roles/openshift_version/defaults/main.yml index 01a1a7472..4adf04e90 100644 --- a/roles/openshift_version/defaults/main.yml +++ b/roles/openshift_version/defaults/main.yml @@ -1,2 +1,8 @@ --- openshift_protect_installed_version: True + +openshift_service_type_dict: + origin: origin + openshift-enterprise: atomic-openshift + +openshift_service_type: "{{ openshift_service_type_dict[openshift_deployment_type] }}" diff --git a/roles/openshift_version/tasks/main.yml b/roles/openshift_version/tasks/main.yml index 4f9158ade..ae0f68a5b 100644 --- a/roles/openshift_version/tasks/main.yml +++ b/roles/openshift_version/tasks/main.yml @@ -101,13 +101,13 @@ when: is_containerized | bool - block: - - name: Get available {{ openshift.common.service_type}} version + - name: Get available {{ openshift_service_type}} version repoquery: - name: "{{ openshift.common.service_type}}" + name: "{{ openshift_service_type}}" ignore_excluders: true register: rpm_results - fail: - msg: "Package {{ openshift.common.service_type}} not found" + msg: "Package {{ openshift_service_type}} not found" when: not rpm_results.results.package_found - set_fact: openshift_rpm_version: "{{ rpm_results.results.versions.available_versions.0 | default('0.0', True) }}" @@ -196,7 +196,7 @@ - openshift_version.startswith(openshift_release) | bool msg: |- You requested openshift_release {{ openshift_release }}, which is not matched by - the latest OpenShift RPM we detected as {{ openshift.common.service_type }}-{{ openshift_version }} + the latest OpenShift RPM we detected as {{ openshift_service_type }}-{{ openshift_version }} on host {{ inventory_hostname }}. We will only install the latest RPMs, so please ensure you are getting the release you expect. You may need to adjust your Ansible inventory, modify the repositories diff --git a/roles/openshift_version/tasks/set_version_rpm.yml b/roles/openshift_version/tasks/set_version_rpm.yml index c40777bf1..c7ca5ceae 100644 --- a/roles/openshift_version/tasks/set_version_rpm.yml +++ b/roles/openshift_version/tasks/set_version_rpm.yml @@ -8,14 +8,14 @@ - openshift_version is not defined - block: - - name: Get available {{ openshift.common.service_type}} version + - name: Get available {{ openshift_service_type}} version repoquery: - name: "{{ openshift.common.service_type}}" + name: "{{ openshift_service_type}}" ignore_excluders: true register: rpm_results - fail: - msg: "Package {{ openshift.common.service_type}} not found" + msg: "Package {{ openshift_service_type}} not found" when: not rpm_results.results.package_found - set_fact: |