diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2017-09-26 02:55:50 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-09-26 02:55:50 -0700 |
commit | fa83e187398b03cb8118234cb92f42c200c5e227 (patch) | |
tree | 8d064b36befc6d15f203fae655f5ac6df12c9099 /roles/openshift_version | |
parent | c16d16d082ae992df3dd63d120622d9179371b17 (diff) | |
parent | f54d66febe0612a175d6e992d694ff0c2aeb6f97 (diff) | |
download | openshift-fa83e187398b03cb8118234cb92f42c200c5e227.tar.gz openshift-fa83e187398b03cb8118234cb92f42c200c5e227.tar.bz2 openshift-fa83e187398b03cb8118234cb92f42c200c5e227.tar.xz openshift-fa83e187398b03cb8118234cb92f42c200c5e227.zip |
Merge pull request #5519 from giuseppe/crio-set-proper-tag
Automatic merge from submit-queue
Detect the proper version of the images when using CRI-O
Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1494357
Diffstat (limited to 'roles/openshift_version')
-rw-r--r-- | roles/openshift_version/tasks/set_version_containerized.yml | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/roles/openshift_version/tasks/set_version_containerized.yml b/roles/openshift_version/tasks/set_version_containerized.yml index a2a579e9d..b727eb74d 100644 --- a/roles/openshift_version/tasks/set_version_containerized.yml +++ b/roles/openshift_version/tasks/set_version_containerized.yml @@ -1,6 +1,6 @@ --- - set_fact: - l_use_crio: "{{ openshift_use_crio | default(false) }}" + l_use_crio_only: "{{ openshift_use_crio_only | default(false) }}" - name: Set containerized version to configure if openshift_image_tag specified set_fact: @@ -22,7 +22,9 @@ command: > docker run --rm {{ openshift.common.cli_image }}:latest version register: cli_image_version - when: openshift_version is not defined + when: + - openshift_version is not defined + - not l_use_crio_only # Origin latest = pre-release version (i.e. v1.3.0-alpha.1-321-gb095e3a) - set_fact: @@ -31,6 +33,7 @@ - openshift_version is not defined - openshift.common.deployment_type == 'origin' - cli_image_version.stdout_lines[0].split('-') | length > 1 + - not l_use_crio_only - set_fact: openshift_version: "{{ cli_image_version.stdout_lines[0].split(' ')[1].split('-')[0][1:] }}" @@ -45,14 +48,14 @@ when: - openshift_version is defined - openshift_version.split('.') | length == 2 - - not l_use_crio + - not l_use_crio_only - set_fact: openshift_version: "{{ cli_image_version.stdout_lines[0].split(' ')[1].split('-')[0:2][1:] | join('-') if openshift.common.deployment_type == 'origin' else cli_image_version.stdout_lines[0].split(' ')[1].split('-')[0][1:] }}" when: - openshift_version is defined - openshift_version.split('.') | length == 2 - - not l_use_crio + - not l_use_crio_only # TODO: figure out a way to check for the openshift_version when using CRI-O. # We should do that using the images in the ostree storage so we don't have |