Skip to content

Commit

Permalink
Add a upgraded zuul job
Browse files Browse the repository at this point in the history
  • Loading branch information
HarryMichal committed Sep 4, 2019
1 parent 4d18abf commit 73c5c50
Show file tree
Hide file tree
Showing 5 changed files with 98 additions and 25 deletions.
26 changes: 20 additions & 6 deletions .zuul.yaml
Original file line number Diff line number Diff line change
@@ -1,16 +1,30 @@
---
- job:
name: toolbox-test
description: Run toolbox test
name: toolbox-test-rpm-30
description: Test toolbox with rpm Podman on Fedora 30
nodeset:
nodes:
- name: ci-node
- name: ci-node-30
label: cloud-fedora-30
run: playbooks/toolbox-test.yaml
pre-run: playbooks/setup-rpm-env.yaml
run: playbooks/toolbox-test-rpm-30.yaml

- job:
name: toolbox-test-git
description: Test toolbox with latest (git) Podman
nodeset:
nodes:
- name: ci-node-30
label: cloud-fedora-30
pre-run: playbooks/setup-git-env.yaml
run: playbooks/toolbox-test-git.yaml

- project:
check:
jobs:
- toolbox-test
- toolbox-test-rpm-30
- toolbox-test-git
gate:
jobs:
- toolbox-test
- toolbox-test-rpm-30
- toolbox-test-git
30 changes: 30 additions & 0 deletions playbooks/setup-git-env.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
- hosts: all
tasks:
- name: Install requirements
become: yes
package:
name:
- golang-github-cpuguy83-go-md2man
- ninja-build
- meson
- flatpak-session-helper
- systemd
- bats
- ShellCheck
- bash-completion
- udisks2
- wget

- name: Setup environment (create missing /run/media)
command: sudo systemd-tmpfiles --create

- name: Make a folder for Podman
file:
path: "{{ zuul.project.src_dir }}/podman"
state: directory

- name: Get latest working Podman build
command: wget https://storage.googleapis.com/libpod-master-releases/libpod-master-fedora-30-amd64.tar.gz -O - | tar -xz
args:
chdir: '{{ zuul.project.src_dir/podman }}'
20 changes: 20 additions & 0 deletions playbooks/setup-rpm-env.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
- hosts: all
tasks:
- name: Install requirements
become: yes
package:
name:
- golang-github-cpuguy83-go-md2man
- ninja-build
- meson
- flatpak-session-helper
- systemd
- bats
- ShellCheck
- bash-completion
- udisks2
- podman

- name: Setup environment (create missing /run/media)
command: sudo systemd-tmpfiles --create
27 changes: 27 additions & 0 deletions playbooks/toolbox-test-git.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
- hosts: ci-node-30
tasks:
- name: Build
command: meson builddir
args:
chdir: '{{ zuul.project.src_dir }}'

- name: Run shellcheck
command: ninja -C builddir test
args:
chdir: '{{ zuul.project.src_dir }}'

- name: Run system tests
ignore_errors: yes
command: PODMAN=./podman/usr/bin/podman TOOLBOX=./toolbox bats test/system
args:
chdir: '{{ zuul.project.src_dir }}'

- name: Test create
command: ./toolbox -y -v create
args:
chdir: '{{ zuul.project.src_dir }}'

- name: Test list
command: ./toolbox -y -v list
args:
chdir: '{{ zuul.project.src_dir }}'
Original file line number Diff line number Diff line change
@@ -1,23 +1,5 @@
- hosts: ci-node
- hosts: ci-node-30
tasks:
- name: Install requirements
become: yes
package:
name:
- golang-github-cpuguy83-go-md2man
- ninja-build
- meson
- podman
- flatpak-session-helper
- systemd
- bats
- ShellCheck
- bash-completion
- udisks2

- name: Setup environment
command: sudo systemd-tmpfiles --create

- name: Build
command: meson builddir
args:
Expand Down

0 comments on commit 73c5c50

Please sign in to comment.