Skip to content

Commit

Permalink
Combined checksum
Browse files Browse the repository at this point in the history
  • Loading branch information
DazWorrall committed Feb 9, 2024
1 parent 0a00fa3 commit 035fcd7
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 7 deletions.
9 changes: 2 additions & 7 deletions .github/workflows/build-deb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,20 @@ sudo apt-get update
sudo apt-get install -y make

# We set this here, so it's the same between the copydb and sharding debian
# package.
DATETIME=$(date -u +%Y%m%d%H%M%S)
# package, and between different arch builds
DATETIME=$(date -u +%Y%m%d)

git status

make copydb-deb DATETIME=${DATETIME}
make sharding-deb DATETIME=${DATETIME}

cd build
sha256sum *.deb > ghostferry-$GITHUB_SHA.sha256sum

set +x

echo "Debian package built successfully as follows:"
ls -l ghostferry*

echo "sha256sum:"
cat ghostferry-$GITHUB_SHA.sha256sum

# Make sure the we didn't release a dirty build by accident
if ls | grep -q dirty; then
echo "ERROR: source directory is not clean! refused to release. showing git status below:"
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,3 +93,21 @@ jobs:
with:
name: debs
path: build/ghostferry*

checksum-debs:
runs-on: ubuntu-latest
needs: build-debs
steps:
- name: Fetch uploaded artifacts
uses: actions/download-artifact@v4
with:
name: debs
- name: shasum
shell: bash
run: |
sha256sum *.deb > ghostferry-$GITHUB_SHA.sha256sum
- name: Upload checksum
uses: actions/upload-artifact@v3
with:
name: debs
path: *.sha256sum

0 comments on commit 035fcd7

Please sign in to comment.