Role to install podman

A simple role to install podman packages.

Change-Id: I135fab8474b3564bb4ab1f2b19d4645d4a86f560
This commit is contained in:
Ian Wienand 2019-11-08 11:16:02 +11:00 committed by Andreas Jaeger
parent 81d7e7a993
commit cdff4b7835
7 changed files with 56 additions and 0 deletions

View File

@ -6,6 +6,7 @@ Container Roles
.. zuul:autorole:: install-docker
.. zuul:autorole:: install-kubernetes
.. zuul:autorole:: install-openshift
.. zuul:autorole:: install-podman
.. zuul:autorole:: promote-docker-image
.. zuul:autorole:: pull-from-intermediate-registry
.. zuul:autorole:: push-to-intermediate-registry

View File

@ -0,0 +1,4 @@
Install podman container manager
**Role Variables**

View File

@ -0,0 +1,12 @@
- name: Install projectatomic PPA
apt_repository:
repo: 'ppa:projectatomic/ppa'
state: present
become: yes
- name: Install podman
package:
name:
- podman
state: present
become: yes

View File

@ -0,0 +1,3 @@
- name: Not implemented
fail:
msg: Role not implemented on this platform yet

View File

@ -0,0 +1,8 @@
- name: Find distribution installation
include: "{{ item }}"
static: no
with_first_found:
- "{{ ansible_distribution }}-{{ ansible_distribution_major_version }}.yaml"
- "{{ ansible_distribution }}.yaml"
- "{{ ansible_os_family }}.yaml"
- "default.yaml"

View File

@ -0,0 +1,14 @@
- hosts: all
roles:
- install-podman
- hosts: all
tasks:
- name: Exercise podman
command: /usr/bin/podman info
register: output
- name: Debug output
debug:
msg: '{{ output.stdout }}'

View File

@ -137,6 +137,19 @@
run: test-playbooks/install-kubernetes/crio.yaml
post-run: test-playbooks/install-kubernetes/post.yaml
- job:
name: zuul-jobs-test-install-podman
description: |
Test the install-podman role
This job tests the install-podman role. It is not meant to be
used directly but rather run on changes to roles in the
zuul-jobs repo.
files:
- roles/install-podman/.*
- test-playbooks/install-podman/.*
run: test-playbooks/install-podman/main.yaml
# List all the jobs in this file.
- project:
@ -147,5 +160,6 @@
- zuul-jobs-test-registry-buildset-registry-k8s-docker
- zuul-jobs-test-install-kubernetes-docker
- zuul-jobs-test-install-kubernetes-crio
- zuul-jobs-test-install-podman
gate:
jobs: *id001