File: build.yml

package info (click to toggle)
clevis 19-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 884 kB
  • sloc: sh: 4,675; ansic: 1,281; makefile: 8
file content (61 lines) | stat: -rw-r--r-- 1,529 bytes parent folder | download
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
---
name: build

on: [push, pull_request]

jobs:
  build:
    runs-on: ubuntu-18.04
    continue-on-error: ${{ ! matrix.stable }}
    strategy:
      matrix:
        os:
          - fedora:latest
          - quay.io/centos/centos:stream8
          - quay.io/centos/centos:stream9
          - debian:testing
          - debian:latest
          - ubuntu:rolling
          - ubuntu:bionic
        stable: [true]
        include:
          - os: fedora:rawhide
            stable: false
          - os: ubuntu:devel
            stable: false
    steps:
      - uses: actions/checkout@v2

      - name: Show OS information
        run: cat /etc/os-release 2>/dev/null || echo /etc/os-release not available

      - name: Install build dependencies
        run: bash .github/workflows/install-dependencies

      - name: Build clevis
        run: |
          mkdir -p build && cd build
          export ninja=$(command -v ninja)
          [ -z "${ninja}" ] && export ninja=$(command -v ninja-build)
          export CFLAGS="-g -coverage"
          meson .. || cat meson-logs/meson-log.txt >&2
          ${ninja}

      - name: Run tests
        run: |
          cd build
          if ! meson test ; then
              cat meson-logs/testlog.txt >&2
              exit -1
          fi

      - name: Show full test logs
        run: cat build/meson-logs/testlog.txt >&2

    container:
      image: ${{matrix.os}}
      env:
        DISTRO: ${{matrix.os}}
      options: --privileged --device /dev/loop-control

# vim:set ts=2 sw=2 et: