Add podman version detection and yum cache

Change-Id: Id9095c67f0a5f3f11c02f932ef432a6046b32b8a
This commit is contained in:
Sagi Shnaidman 2019-10-24 15:51:24 +03:00
parent 9021d52c93
commit 9d31d8996c
2 changed files with 22 additions and 0 deletions

View File

@ -4,6 +4,25 @@
gather_subset: "!min,distribution"
when: ansible_distribution is not defined
- name: Run podman --version
command: podman --version
ignore_errors: true
register: podman_ver
tags:
- undercloud-install
- name: Set fact for podman version
set_fact:
podman_version: >-
{%- if podman_ver is success -%}
{{ podman_ver.stdout | replace("podman version ", "") }}
{%- else -%}0.0
{%- endif -%}
tags:
- undercloud-install
- include: novajoin_prep.yml
when: enable_tls_everywhere|bool and prepare_novajoin|bool
tags:

View File

@ -11,6 +11,9 @@ parameter_defaults:
modify_vars:
tasks_from: yum_update.yml
yum_repos_dir_path: /etc/yum.repos.d
{% if release not in ['pike','queens','rocky','stein'] and podman_version is version('1.5.0', '>=') %}
yum_cache: /var/tmp/tripleo-container-image-prepare-cache
{% endif %}
update_repo: "{{ update_containers_repo }}"
{% if release not in ['newton', 'ocata', 'pike', 'queens', 'rocky'] %}
container_build_tool: buildah