summaryrefslogtreecommitdiffstats
path: root/roles
diff options
context:
space:
mode:
authorScott Dodson <sdodson@redhat.com>2017-11-24 17:02:50 -0500
committerGitHub <noreply@github.com>2017-11-24 17:02:50 -0500
commit0338debbd35254c884487ceb1064b1eabde0149e (patch)
tree1123b1dc344f0342aaafb990ff95d30adb405b0c /roles
parentbd5c01de84be6ccedb7e8b00dddfc6e6e3d0bebf (diff)
parente4db872a66bdb41f6c45b7a3235d09a439c08936 (diff)
downloadopenshift-0338debbd35254c884487ceb1064b1eabde0149e.tar.gz
openshift-0338debbd35254c884487ceb1064b1eabde0149e.tar.bz2
openshift-0338debbd35254c884487ceb1064b1eabde0149e.tar.xz
openshift-0338debbd35254c884487ceb1064b1eabde0149e.zip
Merge pull request #6227 from adelton/issue-5517
Workaround the fact that package state=present with dnf fails for already installed but excluded packages.
Diffstat (limited to 'roles')
-rw-r--r--roles/docker/tasks/package_docker.yml5
1 files changed, 3 insertions, 2 deletions
diff --git a/roles/docker/tasks/package_docker.yml b/roles/docker/tasks/package_docker.yml
index e6c3fe4d7..5437275a2 100644
--- a/roles/docker/tasks/package_docker.yml
+++ b/roles/docker/tasks/package_docker.yml
@@ -1,6 +1,6 @@
---
- name: Get current installed Docker version
- command: "{{ repoquery_cmd }} --installed --qf '%{version}' docker"
+ command: "{{ repoquery_installed }} --qf '%{version}' docker"
when: not openshift.common.is_atomic | bool
register: curr_docker_version
retries: 4
@@ -33,9 +33,10 @@
# Make sure Docker is installed, but does not update a running version.
# Docker upgrades are handled by a separate playbook.
+# Note: The curr_docker_version.stdout check can be removed when https://github.com/ansible/ansible/issues/33187 gets fixed.
- name: Install Docker
package: name=docker{{ '-' + docker_version if docker_version is defined else '' }} state=present
- when: not openshift.common.is_atomic | bool
+ when: not openshift.common.is_atomic | bool and not curr_docker_version | skipped and not curr_docker_version.stdout != ''
- block:
# Extend the default Docker service unit file when using iptables-services