x509: Use proper version for CSR. #252
Workflow file for this run
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
name: Continuous Integration | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
ubuntu: | |
name: Ubuntu | |
runs-on: ${{ matrix.os }} | |
continue-on-error: true | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- ubuntu-20.04 | |
- ubuntu-22.04 | |
compiler: | |
- gcc | |
- clang | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Install build dependencies | |
run: | | |
sudo apt update | |
sudo apt install -y meson pkgconf openssl libssl-dev libpath-utils-dev libtalloc-dev help2man libpopt-dev ${{ matrix.compiler }} | |
sudo apt install -y --no-install-recommends debhelper devscripts lintian | |
# 18.04's debhelper is too old, we want to use compat level 12 | |
if grep -q 18.04 /etc/os-release; then | |
sudo apt install -y -t bionic-backports debhelper | |
fi | |
- name: Configure build directory | |
run: | | |
CC=${{ matrix.compiler}} meson setup ${{ matrix.os }} | |
- name: Build SSCG | |
run: | | |
ninja -C ${{ matrix.os }} | |
- name: Run in-tree tests | |
run: | | |
meson test -t 5 --print-errorlogs -C ${{ matrix.os }} | |
- name: Build Debian source package | |
run: | | |
set -ex | |
mkdir deb | |
# keep version number as 0 for upstream, to match debian/changelog | |
git archive -o deb/sscg_0.orig.tar.gz --prefix sscg/ HEAD | |
cd deb | |
# unpack tar again to make sure the dist is complete and clean | |
tar xf sscg_*.tar.gz | |
cd sscg | |
cp -r packaging/debian . | |
# build source and binary package, with lintian | |
debuild -e CC=${{ matrix.compiler}} -us -uc | |
- name: Install built Debian binary package | |
run: | | |
sudo dpkg -i deb/sscg_*.deb | |
- name: Smoke test installed package | |
run: | | |
cd /tmp/ | |
sscg | |
openssl x509 -in service.pem -text | |
openssl x509 -in ca.crt -text | |
get_fedora_releases: | |
name: Get Fedora Releases | |
runs-on: ubuntu-latest | |
steps: | |
- name: Query Fedora | |
id: releases | |
uses: sgallagher/get-fedora-releases-action@v1 | |
outputs: | |
stable: ${{ steps.releases.outputs.stable }} | |
development: ${{ steps.releases.outputs.development }} | |
active: ${{ steps.releases.outputs.active }} | |
fedora: | |
name: Fedora x86_64 | |
runs-on: ubuntu-latest | |
needs: get_fedora_releases | |
strategy: | |
fail-fast: false | |
matrix: | |
release: ${{ fromJson(needs.get_fedora_releases.outputs.active) }} | |
compiler: | |
- gcc | |
- clang | |
container: | |
image: quay.io/fedora/fedora:${{ matrix.release }} | |
options: --security-opt seccomp=unconfined | |
steps: | |
- name: Identify the system | |
run: | | |
cat /etc/os-release | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Install build dependencies | |
run: | | |
dnf install -y meson pkgconf openssl openssl-devel libpath_utils-devel libtalloc-devel help2man popt-devel ${{ matrix.compiler }} | |
- name: Configure build directory | |
run: | | |
CC=${{ matrix.compiler}} meson setup fedora-${{ matrix.release }} | |
- name: Build SSCG | |
run: | | |
ninja -C fedora-${{ matrix.release }} | |
- name: Run in-tree tests | |
run: | | |
meson test -t 5 --print-errorlogs -C fedora-${{ matrix.release }} | |
fedora_multiarch: | |
name: Fedora non-x86_64 | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
arch: | |
- aarch64 | |
- ppc64le | |
compiler: | |
- gcc | |
- clang | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- uses: uraimo/run-on-arch-action@v2 | |
name: Perform upstream tests | |
with: | |
arch: ${{ matrix.arch }} | |
distro: fedora_latest | |
# Not required, but speeds up builds by storing container images in | |
# a GitHub package registry. | |
githubToken: ${{ github.token }} | |
install: | | |
dnf update -y --refresh | |
dnf install -y meson pkgconf openssl openssl-devel libpath_utils-devel libtalloc-devel help2man popt-devel ${{ matrix.compiler }} | |
run: | | |
CC=${{ matrix.compiler}} meson setup fedora-${{ matrix.arch }} | |
ninja -C fedora-${{ matrix.arch }} | |
meson test -t 15 --print-errorlogs -C fedora-${{ matrix.arch }} | |
centos-stream: | |
name: CentOS Stream | |
runs-on: ubuntu-latest | |
continue-on-error: false | |
strategy: | |
fail-fast: false | |
matrix: | |
release: | |
- 8 | |
- 9 | |
compiler: | |
- gcc | |
- clang | |
container: | |
image: quay.io/centos/centos:stream${{ matrix.release }} | |
options: --security-opt seccomp=unconfined | |
steps: | |
- name: Identify the system | |
run: | | |
cat /etc/os-release | |
- name: Checkout SSCG code | |
uses: actions/checkout@v3 | |
- name: Enable DNF tools | |
run: | | |
yum -y install dnf-plugins-core | |
- name: Enable CRB | |
if: matrix.release > 8 | |
run: | | |
yum config-manager --set-enabled crb | |
- name: Enable PowerTools | |
if: matrix.release == 8 | |
run: | | |
yum config-manager --set-enabled powertools | |
- name: Install build dependencies | |
run: | | |
yum install -y meson pkgconf-pkg-config openssl openssl-devel libpath_utils-devel libtalloc-devel help2man popt-devel ${{ matrix.compiler }} | |
- name: Configure build directory | |
run: | | |
CC=${{ matrix.compiler}} meson setup --errorlogs centos-stream-${{ matrix.release }} || ( cat centos-stream-${{ matrix.release }}/meson-logs/meson-log.txt && exit 1 ) | |
- name: Build SSCG | |
run: | | |
ninja -C centos-stream-${{ matrix.release }} | |
- name: Run in-tree tests | |
run: | | |
meson test -t 5 --print-errorlogs -C centos-stream-${{ matrix.release }} |