From a84b5ecb0128e1fd21ac6526bbc8e8ff3e574e41 Mon Sep 17 00:00:00 2001 From: Cole Miller Date: Tue, 3 Sep 2024 02:38:47 -0400 Subject: [PATCH] Debugging Signed-off-by: Cole Miller --- .github/workflows/debug-gpg.yml | 46 +++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 .github/workflows/debug-gpg.yml diff --git a/.github/workflows/debug-gpg.yml b/.github/workflows/debug-gpg.yml new file mode 100644 index 000000000..bb87b114b --- /dev/null +++ b/.github/workflows/debug-gpg.yml @@ -0,0 +1,46 @@ +name: Debug GPG +on: [push, pull_request] +jobs: + build: + runs-on: ubuntu-20.04 + environment: + name: debugging-gpg + steps: + - name: Clone the repositories + run: | + git clone https://github.com/canonical/dqlite + git clone https://github.com/canonical/dqlite-ppa -b dqlite --depth 1 + + - name: Setup dependencies + run: | + sudo apt-get update -qq + sudo apt-get install -qq debhelper devscripts gnupg + + - name: Setup dummy GPG signing key + env: + DUMMY_SECRET_KEY: ${{ secrets.DUMMY_SECRET_KEY }} + run: | + echo "$DUMMY_SECRET_KEY" > private-key.asc + wc private-key.asc + gpg --import --batch private-key.asc + + - name: Delete GPG signing key file + if: always() + run: | + rm -f private-key.asc + + - name: Build source package + env: + DEBFULLNAME: "nobody" + DEBEMAIL: "nobody@example.org" + TARGET: "noble" + run: | + cp -R dqlite-ppa/debian dqlite/ + cd dqlite/ + VERSION="$(git describe --tags | sed -e "s/^v//" -e "s/-/+git/")" + dch --create \ + --distribution ${TARGET} \ + --package dqlite \ + --newversion ${VERSION}~${TARGET}1 \ + "Automatic build from Github" + debuild -S -sa -d -k$DUMMY_PUBLIC_KEY