|
@@ -11,7 +11,7 @@
|
|
- name: Error out if Docker pre-installed but too old
|
|
- name: Error out if Docker pre-installed but too old
|
|
fail:
|
|
fail:
|
|
msg: "Docker {{ curr_docker_version.stdout }} is installed, but >= 1.9.1 is required."
|
|
msg: "Docker {{ curr_docker_version.stdout }} is installed, but >= 1.9.1 is required."
|
|
- when: not curr_docker_version | skipped and curr_docker_version.stdout != '' and curr_docker_version.stdout | version_compare('1.9.1', '<') and not docker_version is defined and not docker_protect_installed_version | bool
|
|
|
|
|
|
+ when: not curr_docker_version | skipped and curr_docker_version.stdout != '' and curr_docker_version.stdout | version_compare('1.9.1', '<') and not docker_version is defined
|
|
|
|
|
|
- name: Error out if requested Docker is too old
|
|
- name: Error out if requested Docker is too old
|
|
fail:
|
|
fail:
|
|
@@ -31,19 +31,19 @@
|
|
- name: Fail if Docker version requested but downgrade is required
|
|
- name: Fail if Docker version requested but downgrade is required
|
|
fail:
|
|
fail:
|
|
msg: "Docker {{ curr_docker_version.stdout }} is installed, but version {{ docker_version }} was requested."
|
|
msg: "Docker {{ curr_docker_version.stdout }} is installed, but version {{ docker_version }} was requested."
|
|
- when: not curr_docker_version | skipped and curr_docker_version.stdout != '' and docker_version is defined and curr_docker_version.stdout | version_compare(docker_version, '>') and not docker_protect_installed_version | bool
|
|
|
|
|
|
+ when: not curr_docker_version | skipped and curr_docker_version.stdout != '' and docker_version is defined and curr_docker_version.stdout | version_compare(docker_version, '>')
|
|
|
|
|
|
# This involves an extremely slow migration process, users should instead run the
|
|
# This involves an extremely slow migration process, users should instead run the
|
|
# Docker 1.10 upgrade playbook to accomplish this.
|
|
# Docker 1.10 upgrade playbook to accomplish this.
|
|
- name: Error out if attempting to upgrade Docker across the 1.10 boundary
|
|
- name: Error out if attempting to upgrade Docker across the 1.10 boundary
|
|
fail:
|
|
fail:
|
|
msg: "Cannot upgrade Docker to >= 1.10, please upgrade or remove Docker manually, or use the Docker upgrade playbook if OpenShift is already installed."
|
|
msg: "Cannot upgrade Docker to >= 1.10, please upgrade or remove Docker manually, or use the Docker upgrade playbook if OpenShift is already installed."
|
|
- when: not curr_docker_version | skipped and curr_docker_version.stdout != '' and curr_docker_version.stdout | version_compare('1.10', '<') and docker_version is defined and docker_version | version_compare('1.10', '>=') and not docker_protect_installed_version | bool
|
|
|
|
|
|
+ when: not curr_docker_version | skipped and curr_docker_version.stdout != '' and curr_docker_version.stdout | version_compare('1.10', '<') and docker_version is defined and docker_version | version_compare('1.10', '>=')
|
|
|
|
|
|
# Make sure Docker is installed, but does not update a running version.
|
|
# Make sure Docker is installed, but does not update a running version.
|
|
# Docker upgrades are handled by a separate playbook.
|
|
# Docker upgrades are handled by a separate playbook.
|
|
- name: Install Docker
|
|
- name: Install Docker
|
|
- action: "{{ ansible_pkg_mgr }} name=docker{{ '-' + docker_version if docker_version is defined and not docker_protect_installed_version | bool else '' }} state=present"
|
|
|
|
|
|
+ action: "{{ ansible_pkg_mgr }} 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
|
|
|
|
|
|
- name: Start the Docker service
|
|
- name: Start the Docker service
|