-
Notifications
You must be signed in to change notification settings - Fork 33
67 lines (55 loc) · 1.65 KB
/
build-cirros.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: CirrOS image builder
on:
push:
branches:
- main
tags:
- "[01].[0-9]+.[0-9]+"
pull_request:
branches:
- main
jobs:
cirros-build-matrix:
strategy:
matrix:
arch: [aarch64, arm, x86_64, ppc64le]
runs-on: ubuntu-22.04
env:
ARCHES: ${{ matrix.arch }}
QUIET: 1
CI_BUILD: "true"
CI_BUILD_OUT: "build-ci/"
steps:
- name: Pull cirros source artifacts
uses: actions/checkout@v4
- name: Cache download
uses: actions/cache@v4
with:
key: downloads-${{ matrix.arch }}-${{ hashFiles('bin/build-release') }}
path: download/
- name: Cache ccache
uses: actions/cache@v4
with:
key: ccache-${{ matrix.arch }}-${{ hashFiles('bin/build-release') }}
path: ccache/
- name: Prepare job environment
run: bin/system-setup
- name: Install job dependencies
run: sudo apt-get install cloud-utils qemu-system openbios-ppc
- name: disable invisible-mirror.net use
run: echo "127.0.0.1 invisible-mirror.net" | sudo tee -a /etc/hosts
- name: Build CirrOS image
env:
# use tag name for tag build, or 'daily' for anything else.
reason: "${{ github.ref_type == 'tag' && github.ref_name || 'daily' }}"
run: bin/build-release "$reason"
- name: Boot CirrOS image
run: bin/test-boot
env:
GUESTARCH: ${{ matrix.arch }}
POWEROFF: "true"
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: cirros-${{ matrix.arch }}
path: build-ci/release/