Merge remote-tracking branch 'debuerreotype-vicamo/for-upstream/build… #159
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: GitHub CI | |
on: | |
pull_request: | |
push: | |
schedule: | |
- cron: 0 0 * * 0 | |
workflow_dispatch: | |
defaults: | |
run: | |
shell: 'bash -Eeuo pipefail -x {0}' | |
concurrency: | |
group: ${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
https: | |
name: Ensure no-TLS snapshot usage | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Ensure http://snapshot.debian.org (https://github.com/debuerreotype/debuerreotype/pull/119#issuecomment-901457009) | |
run: | | |
rm .github/workflows/ci.yml # this file itself will always be a match, but it's the only valid one 👀 | |
if grep -rn 'https://snapshot.debian.org'; then | |
exit 1 | |
fi | |
image: | |
runs-on: ubuntu-latest | |
outputs: | |
metadata: ${{ steps.build.outputs.metadata }} | |
steps: | |
- name: Checkout Debuerreotype | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
with: | |
version: v0.12.0 | |
- name: Build and push | |
id: build | |
uses: docker/build-push-action@v5 | |
with: | |
context: '.' | |
outputs: type=docker,dest=/tmp/debuerreotype.tar | |
tags: local/debuerreotype:latest | |
- name: Upload debuerreotype image tarball | |
uses: actions/upload-artifact@v4 | |
with: | |
name: debuerreotype | |
path: /tmp/debuerreotype.tar | |
test: | |
needs: | |
- image | |
strategy: | |
matrix: | |
include: | |
- { SUITE: stable, CODENAME: jessie, TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 6bec1ad527391127159338d2e82e7bcd5d29dc95d766d6aa374f3b3e850b9d76 } | |
- { SUITE: jessie, CODENAME: "", TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 6bec1ad527391127159338d2e82e7bcd5d29dc95d766d6aa374f3b3e850b9d76 } | |
- { SUITE: testing, CODENAME: stretch, TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 6dac0c6f25953747754421d258351e19ba06b2a9cf5076fa9b0bad470cba2992 } | |
- { SUITE: stretch, CODENAME: "", TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 6dac0c6f25953747754421d258351e19ba06b2a9cf5076fa9b0bad470cba2992 } | |
- { SUITE: unstable, CODENAME: sid, TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 8d0e577a6bf851507bb9621c638c12b3e8ee0408519d33a51af41771fd30a8bc } | |
- { SUITE: sid, CODENAME: "", TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 8d0e577a6bf851507bb9621c638c12b3e8ee0408519d33a51af41771fd30a8bc } | |
- { SUITE: oldstable, CODENAME: wheezy, TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 03f69a953780cf00e4d948e510316a8c921c3cab3b29ca8875a66ba167ce8685 } | |
- { SUITE: wheezy, CODENAME: "", TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 03f69a953780cf00e4d948e510316a8c921c3cab3b29ca8875a66ba167ce8685 } | |
# EOL suites testing | |
- { SUITE: eol, CODENAME: etch, TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 5d423f735b56944fe114a4d7e09defe68cc2f038c03e1a317fa2b22094cf4add } | |
- { SUITE: eol, CODENAME: lenny, TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: 7ed0cc3787708dc4e18eb2b0c145942e153dd0b5fd7dbc6a5a0bc0f797424d00 } | |
- { SUITE: eol, CODENAME: woody, ARCH: i386, TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: f80833896e141fbfebf8c91e79da2ccca1bdeb8f8ecc4e05dd33531c32857e0f } | |
- { SUITE: eol, CODENAME: jessie, TIMESTAMP: "2021-03-01T00:00:00Z", SHA256: 0fbf1bcba51788e82abeee22c722937fcdccb7691acbe9a006b5e2e1e9269ced } | |
# deb822 / usr-is-merged testing | |
- { SUITE: unstable, CODENAME: "", TIMESTAMP: "2022-09-30T00:00:00Z", SHA256: 356fcc802434e62f0fc119564ed1e8928e8dd214ba5d60ebe6c21ad90114e030 } | |
- { SUITE: bookworm, CODENAME: "", TIMESTAMP: "2022-09-30T00:00:00Z", SHA256: 3d987ea3627beb48477a938869b6533afa85b7a3523a1dc85adab47ce2b7ebc3 } | |
- { SUITE: bullseye, CODENAME: "", TIMESTAMP: "2022-09-30T00:00:00Z", SHA256: 34b966f822739d7e60084ab2510be0c517630e664331a6778d63f102830e0b92 } | |
# qemu-debootstrap testing | |
- { ARCH: arm64, SUITE: jessie, CODENAME: "", TIMESTAMP: "2017-01-01T00:00:00Z", SHA256: e46787693f59f29613ebea25d89e52c51f5744a4917ff65d98791d0fe7ffb8a3 } | |
- { ARCH: sh4, SUITE: unstable, CODENAME: "", TIMESTAMP: "2022-02-01T00:00:00Z", SHA256: 4e1a8ab49496787a18f65d4c591b9b2548fa9f2b35b62d95ade194209b16c011 } | |
- { ARCH: riscv64, SUITE: unstable, CODENAME: "", TIMESTAMP: "2022-02-01T00:00:00Z", SHA256: da9282e5f748c3b8bb52eb13b31e5d72f31dcb14af95d41f30fc03660590230e } | |
# a few entries for "today" to try and catch issues like https://github.com/debuerreotype/debuerreotype/issues/41 sooner | |
- { SUITE: unstable, CODENAME: "", TIMESTAMP: "today 00:00:00", SHA256: "" } | |
- { SUITE: stable, CODENAME: "", TIMESTAMP: "today 00:00:00", SHA256: "" } | |
- { SUITE: oldstable, CODENAME: "", TIMESTAMP: "today 00:00:00", SHA256: "" } | |
- { DISTRO: ubuntu, SUITE: eol, CODENAME: breezy } | |
- { DISTRO: ubuntu, SUITE: eol, CODENAME: gutsy } | |
- { DISTRO: ubuntu, SUITE: bionic } | |
- { DISTRO: ubuntu, SUITE: eol, CODENAME: cosmic, ARCH: armhf } | |
- { DISTRO: ubuntu, SUITE: focal } | |
- { DISTRO: ubuntu, SUITE: focal, ARCH: i386 } | |
- { DISTRO: ubuntu, SUITE: jammy } | |
- { DISTRO: ubuntu, SUITE: noble } | |
fail-fast: false | |
name: Test ${{ matrix.DISTRO && format('{0} ', matrix.DISTRO) }}${{ matrix.SUITE }}${{ matrix.CODENAME && format(' ({0})', matrix.CODENAME) }}${{ matrix.ARCH && format(' [{0}]', matrix.ARCH) }}${{ matrix.TIMESTAMP && format(' at {0}', matrix.TIMESTAMP) }} | |
runs-on: ubuntu-20.04 | |
env: ${{ matrix }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
with: | |
version: v0.12.0 | |
- name: Download debuerreotype image tarball | |
uses: actions/download-artifact@v4 | |
with: | |
name: debuerreotype | |
path: /tmp | |
- name: Load debuerreotype image | |
run: docker load --input /tmp/debuerreotype.tar | |
- name: Prepare Environment | |
run: | | |
sudo apt-get update -qq | |
sudo apt-get install -yqq binfmt-support qemu-user-static | |
docker run -d --name squignix --restart always tianon/squignix | |
git clone --depth 1 https://github.com/tianon/pgp-happy-eyeballs.git ~/phe | |
~/phe/hack-my-builds.sh | |
rm -rf ~/phe | |
- name: Build | |
env: | |
IMAGE: ${{ fromJSON(needs.image.outputs.metadata)['image.name'] }} | |
run: | | |
"./.validate-${DISTRO:-debian}.sh" |