2016-12-13 23:36:17 +08:00
|
|
|
---
|
|
|
|
- name: gather os specific variables for rkt
|
|
|
|
include_vars: "{{ item }}"
|
|
|
|
with_first_found:
|
|
|
|
- files:
|
2017-08-24 17:09:52 +08:00
|
|
|
- "{{ ansible_distribution|lower }}-{{ ansible_distribution_version|lower|replace('/', '_') }}.yml"
|
|
|
|
- "{{ ansible_distribution|lower }}-{{ ansible_distribution_release }}.yml"
|
|
|
|
- "{{ ansible_distribution|lower }}-{{ ansible_distribution_major_version|lower|replace('/', '_') }}.yml"
|
|
|
|
- "{{ ansible_distribution|lower }}.yml"
|
|
|
|
- "{{ ansible_os_family|lower }}.yml"
|
|
|
|
- defaults.yml
|
2016-12-13 23:36:17 +08:00
|
|
|
paths:
|
2017-08-24 17:09:52 +08:00
|
|
|
- ../vars
|
2016-12-13 23:36:17 +08:00
|
|
|
skip: true
|
2017-10-05 15:43:04 +08:00
|
|
|
tags:
|
|
|
|
- facts
|
2016-12-13 23:36:17 +08:00
|
|
|
|
2018-04-23 19:28:24 +08:00
|
|
|
- name: install rkt pkg on ubuntu
|
|
|
|
apt:
|
|
|
|
deb: "{{ rkt_download_url }}/{{ rkt_pkg_name }}"
|
2016-12-13 23:36:17 +08:00
|
|
|
state: present
|
|
|
|
register: rkt_task_result
|
2017-03-17 17:55:17 +08:00
|
|
|
until: rkt_task_result|succeeded
|
2016-12-13 23:36:17 +08:00
|
|
|
retries: 4
|
|
|
|
delay: "{{ retry_stagger | random + 3 }}"
|
2018-04-23 19:28:24 +08:00
|
|
|
when: ansible_os_family == "Debian"
|
|
|
|
|
2018-09-20 01:57:20 +08:00
|
|
|
- name: install rkt pkg on fedora
|
|
|
|
dnf:
|
|
|
|
name: rkt
|
|
|
|
state: present
|
|
|
|
when: ansible_distribution == "Fedora"
|
|
|
|
|
2018-04-23 19:28:24 +08:00
|
|
|
- name: install rkt pkg on centos
|
|
|
|
yum:
|
|
|
|
pkg: "{{ rkt_download_url }}/{{ rkt_pkg_name }}"
|
|
|
|
state: present
|
|
|
|
register: rkt_task_result
|
|
|
|
until: rkt_task_result|succeeded
|
|
|
|
retries: 4
|
|
|
|
delay: "{{ retry_stagger | random + 3 }}"
|
2018-09-20 01:57:20 +08:00
|
|
|
when:
|
|
|
|
- ansible_os_family == "RedHat"
|
|
|
|
- ansible_distribution != "Fedora"
|
2018-04-26 17:52:06 +08:00
|
|
|
|
|
|
|
- name: install rkt pkg on openSUSE
|
|
|
|
zypper:
|
|
|
|
name: "{{ rkt_download_url }}/{{ rkt_pkg_name }}"
|
|
|
|
state: present
|
|
|
|
register: rkt_task_result
|
|
|
|
until: rkt_task_result|succeeded
|
|
|
|
retries: 4
|
|
|
|
delay: "{{ retry_stagger | random + 3 }}"
|
|
|
|
when: ansible_os_family == "Suse"
|