Merge pull request #296 from mattymo/forcedockerpkg

Force install of specified docker version, fixes #295
pull/304/head
Smaine Kahlouch 2016-06-17 12:11:04 +02:00 committed by GitHub
commit 47061a31e2
8 changed files with 12 additions and 8 deletions

View File

@ -48,7 +48,8 @@
- name: ensure docker packages are installed - name: ensure docker packages are installed
action: "{{ docker_package_info.pkg_mgr }}" action: "{{ docker_package_info.pkg_mgr }}"
args: args:
pkg: "{{item}}" pkg: "{{item.name}}"
force: "{{item.force|default(omit)}}"
state: present state: present
with_items: "{{ docker_package_info.pkgs }}" with_items: "{{ docker_package_info.pkgs }}"
when: (ansible_os_family != "CoreOS") and (docker_package_info.pkgs|length > 0) when: (ansible_os_family != "CoreOS") and (docker_package_info.pkgs|length > 0)

View File

@ -5,7 +5,7 @@ docker_kernel_min_version: '2.6.32-431'
docker_package_info: docker_package_info:
pkg_mgr: yum pkg_mgr: yum
pkgs: pkgs:
- docker-io - name: docker-io
docker_repo_key_info: docker_repo_key_info:
pkg_key: '' pkg_key: ''

View File

@ -9,7 +9,8 @@ docker_versioned_pkg:
docker_package_info: docker_package_info:
pkg_mgr: apt pkg_mgr: apt
pkgs: pkgs:
- "{{ docker_versioned_pkg[docker_version] }}" - name: "{{ docker_versioned_pkg[docker_version] }}"
force: yes
docker_repo_key_info: docker_repo_key_info:
pkg_key: apt_key pkg_key: apt_key

View File

@ -5,7 +5,7 @@ docker_kernel_min_version: '0'
docker_package_info: docker_package_info:
pkg_mgr: yum pkg_mgr: yum
pkgs: pkgs:
- docker-io - name: docker-io
docker_repo_key_info: docker_repo_key_info:
pkg_key: '' pkg_key: ''

View File

@ -8,7 +8,7 @@ docker_versioned_pkg:
docker_package_info: docker_package_info:
pkg_mgr: dnf pkg_mgr: dnf
pkgs: pkgs:
- "{{ docker_versioned_pkg[docker_version] }}" - name: "{{ docker_versioned_pkg[docker_version] }}"
docker_repo_key_info: docker_repo_key_info:
pkg_key: '' pkg_key: ''

View File

@ -3,7 +3,7 @@ docker_kernel_min_version: '0'
docker_package_info: docker_package_info:
pkg_mgr: yum pkg_mgr: yum
pkgs: pkgs:
- docker-engine - name: docker-engine
docker_repo_key_info: docker_repo_key_info:
pkg_key: '' pkg_key: ''

View File

@ -10,7 +10,8 @@ docker_versioned_pkg:
docker_package_info: docker_package_info:
pkg_mgr: apt pkg_mgr: apt
pkgs: pkgs:
- "{{ docker_versioned_pkg[docker_version] }}" - name: "{{ docker_versioned_pkg[docker_version] }}"
force: yes
docker_repo_key_info: docker_repo_key_info:
pkg_key: apt_key pkg_key: apt_key

View File

@ -10,7 +10,8 @@ docker_versioned_pkg:
docker_package_info: docker_package_info:
pkg_mgr: apt pkg_mgr: apt
pkgs: pkgs:
- "{{ docker_versioned_pkg[docker_version] }}" - name: "{{ docker_versioned_pkg[docker_version] }}"
force: yes
docker_repo_key_info: docker_repo_key_info:
pkg_key: apt_key pkg_key: apt_key