docker: remove obsoletes=0 in yum.conf
This was introduced in ef7f5edbb3
obsoletes=0 is not present in the official repo config
https://download.docker.com/linux/centos/docker-ce.repo
so it might not be needed for some time
Signed-off-by: Etienne Champetier <champetier.etienne@gmail.com>
pull/7160/head
parent
09e34d29cd
commit
b2f6ed7dee
|
@ -24,10 +24,7 @@ docker_dns_servers_strict: true
|
|||
|
||||
docker_container_storage_setup: false
|
||||
|
||||
# Used to override obsoletes=0
|
||||
yum_conf: /etc/yum.conf
|
||||
yum_repo_dir: /etc/yum.repos.d
|
||||
docker_yum_conf: /etc/yum_docker.conf
|
||||
|
||||
# Fedora docker-ce repo
|
||||
docker_fedora_repo_base_url: 'https://download.docker.com/linux/fedora/{{ ansible_distribution_major_version }}/$basearch/stable'
|
||||
|
|
|
@ -144,28 +144,11 @@
|
|||
- ansible_distribution in ["CentOS","RedHat"] and not is_ostree
|
||||
- yum_result.results | length == 0
|
||||
|
||||
- name: Copy yum.conf for editing
|
||||
copy:
|
||||
src: "{{ yum_conf }}"
|
||||
dest: "{{ docker_yum_conf }}"
|
||||
remote_src: yes
|
||||
when: ansible_distribution in ["CentOS","RedHat","OracleLinux"] and not is_ostree
|
||||
|
||||
- name: Edit copy of yum.conf to set obsoletes=0
|
||||
ini_file:
|
||||
path: "{{ docker_yum_conf }}"
|
||||
section: main
|
||||
option: obsoletes
|
||||
value: "0"
|
||||
no_extra_spaces: true
|
||||
when: ansible_distribution in ["CentOS","RedHat","OracleLinux"] and not is_ostree
|
||||
|
||||
- name: ensure docker packages are installed
|
||||
action: "{{ docker_package_info.pkg_mgr }}"
|
||||
args:
|
||||
pkg: "{{ item.name }}"
|
||||
force: "{{ item.force|default(omit) }}"
|
||||
conf_file: "{{ item.yum_conf|default(omit) }}"
|
||||
state: "{{ item.state | default('present') }}"
|
||||
update_cache: "{{ omit if ansible_distribution == 'Fedora' else True }}"
|
||||
enablerepo: "{{ item.repo | default(omit) }}"
|
||||
|
|
|
@ -31,21 +31,16 @@ docker_selinux_versioned_pkg:
|
|||
|
||||
docker_pkgs_use_docker_ce:
|
||||
- name: "{{ docker_selinux_versioned_pkg[docker_selinux_version | string] }}"
|
||||
yum_conf: "{{ docker_yum_conf }}"
|
||||
repo: "docker-ce"
|
||||
- name: "{{ docker_versioned_pkg[docker_version | string] }}"
|
||||
yum_conf: "{{ docker_yum_conf }}"
|
||||
repo: "docker-ce"
|
||||
|
||||
docker_pkgs:
|
||||
- name: "{{ containerd_versioned_pkg[containerd_version | string] }}"
|
||||
yum_conf: "{{ docker_yum_conf }}"
|
||||
repo: "docker-ce"
|
||||
- name: "{{ docker_cli_versioned_pkg[docker_cli_version | string] }}"
|
||||
yum_conf: "{{ docker_yum_conf }}"
|
||||
repo: "docker-ce"
|
||||
- name: "{{ docker_versioned_pkg[docker_version | string] }}"
|
||||
yum_conf: "{{ docker_yum_conf }}"
|
||||
repo: "docker-ce"
|
||||
|
||||
docker_package_info:
|
||||
|
|
Loading…
Reference in New Issue