Skip to content

Commit

Permalink
hack4
Browse files Browse the repository at this point in the history
  • Loading branch information
metux committed Aug 29, 2023
1 parent 73b5c7a commit 4774f48
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
#!/bin/bash

set -e

export DEBIAN_FRONTEND=noninteractive
export DEBPKG_GITHUB_ANONYMOUS=1
## generate a temporary gpp key for signing apt repo

sudo apt-get install -y debootstrap
set -e

HOSTNAME=`hostname -f`
USERNAME=`whoami`
Expand All @@ -18,5 +15,3 @@ gpg --full-gen-key --batch <(echo "Key-Type: 1"; \
echo "Name-Real: Github build user"; \
echo "Name-Email: $USERNAME@$HOSTNAME"; \
echo "%no-protection"; )

./build.devuan-chimaera
50 changes: 48 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,54 @@ jobs:
name: on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
timeout-minutes: 1440
env:
DEBPKG_GITHUB_ANONYMOUS: 1
DEBIAN_FRONTEND: noninteractive
steps:
- uses: actions/[email protected]
- name: Clone repo
uses: actions/checkout@v3
with:
fetch-depth: 5
- run: ./.github/scripts/run-test.sh

- name: Tool install
run: sudo apt-get install -y debootstrap

# make sure we have *some* GPG key for apt repo signing
# doesn't need to be kept secure as nobody really trusts it anyways

- name: Cache gpg key
id: cache-gpg
uses: actions/cache@v3
with:
path: ~/.gnupg
key: gnupg

- if: ${{ steps.cache-gpg.outputs.cache-hit != 'true' }}
name: Generate gpg key (if necessary)
run: ./.github/scripts/gen-gpg-key.sh

# cache apt repo and state, so we don't need full rebuild every time
# note: for different branches, need different name

- name: Cache apt repo and state files
id: cache-repo
uses: actions/cache@v3
with:
path: |
${{ github.workspace }}/.aptrepo
${{ github.workspace }}/.stat
key: repobuild-${{ runner.os }}-${{ runner.arch }}-${{ matrix.os }}+${{ github.ref_name }}@${{ hashFiles('cf/**/*.yml') }}
restore-keys: |
repobuild-${{ runner.os }}-${{ runner.arch }}-${{ matrix.os }}+${{ github.ref_name }}@${{ hashFiles('cf/**/*.yml') }}
repobuild-${{ runner.os }}-${{ runner.arch }}-${{ matrix.os }}+${{ github.ref_name }}@
# run the actual builders

- name: Run builders
run: |
for scr in ./build.* ; do
if [ -x $scr ]; then
echo "---> Calling builder: $scr"
$scr || exit $?
fi
done

0 comments on commit 4774f48

Please sign in to comment.