Bump actions/upload-artifact from 3 to 4 (#25) #62
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# based on https://github.com/ruzickap/ansible-my_workstation/blob/main/.github/workflows/fedora.yml | |
name: CI in Virtualbox (slow) | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- 'Vagrantfile' | |
- '.github/workflows/ci-vm.yml' | |
- '.playbook.yaml' | |
- 'git-repos.txt' | |
- 'vm-resources/**' | |
workflow_dispatch: | |
inputs: | |
uploadVmImage: | |
description: 'Upload image of the built vm' | |
required: true | |
default: 'false' | |
env: | |
VAGRANT_DEFAULT_PROVIDER: virtualbox | |
jobs: | |
virtualbox: | |
runs-on: macos-12 | |
timeout-minutes: 100 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Start VM to build tools from source | |
run: | | |
vagrant up || ( vagrant destroy --force && vagrant up ) | |
- name: Check systemd version | |
run: vagrant ssh --command "systemctl --version" | |
- name: Check systemd status | |
run: vagrant ssh --command "systemctl status" | |
- name: Check version of built tools | |
run: vagrant ssh --command "bash test-scripts/versions.sh" | |
- name: Check basic podman functionality | |
run: vagrant ssh --command "bash test-scripts/podman.sh" | |
- name: Check basic skopeo functionality | |
run: vagrant ssh --command "bash test-scripts/skopeo.sh" | |
- name: Run pytest tests | |
run: | | |
vagrant ssh --command "cd ~/test-scripts/ && pytest -sv" | |
- name: Package VM | |
run: | | |
vagrant package --debug --no-tty --output containers-lab.box --info info.json | |
- run: ls -la | |
- uses: actions/upload-artifact@v4 | |
if: github.event.inputs.uploadVmImage | |
with: | |
name: containers-lab-vagrant-box | |
path: containers-lab.box |