Skip to content

Commit

Permalink
Upload debian package as asset to release (with the same tag as the b…
Browse files Browse the repository at this point in the history
…uilt webx-engine version)
  • Loading branch information
stuartcaunt committed Dec 17, 2024
1 parent c9b1011 commit 5b92d32
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion .github/workflows/build-and-publish-deb.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,28 @@ jobs:
docker build -t webx-engine-builder -f docker/Dockerfile.ubuntu .
- name: Extract Debian package
id: docker_build
run: |
CONTAINER_ID=$(docker create webx-engine-builder)
docker cp $CONTAINER_ID:/app/target/ubuntu/. ./debian-package
docker cp $CONTAINER_ID:/app/VERSION ./debian-package
docker rm -f $CONTAINER_ID
PACKAGE_VERSION=$(cat ./debian-package/VERSION)
mv ./debian-package/webx-engine_${PACKAGE_VERSION}_amd64.deb ./debian-package/webx-engine_${PACKAGE_VERSION}_ubuntu_22.04_amd64.deb
rm ./debian-package/VERSION
echo "::set-output name=version::${PACKAGE_VERSION}"
- name: Upload Debian package to GHCR
uses: actions/upload-artifact@v3
with:
name: debian-package
path: ./debian-package/

- name: Upload Debian package as Release asset
if: github.event_name == 'workflow_dispatch'
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
artifacts: debian-package/*.deb
tag: ${{ steps.docker_build.outputs.version }}
name: "WebX Engine Debian Packages"
body: "Automatically built and uploaded Debian packages."

0 comments on commit 5b92d32

Please sign in to comment.