Skip to content
This repository has been archived by the owner on May 23, 2024. It is now read-only.

Commit

Permalink
Publish for systemd-sysupdate
Browse files Browse the repository at this point in the history
  • Loading branch information
mback2k committed Feb 4, 2024
1 parent 9d9c2fa commit 7cc94c8
Showing 1 changed file with 29 additions and 20 deletions.
49 changes: 29 additions & 20 deletions .github/workflows/sysext.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ jobs:
steps:
- run: sudo apt install -y ninja-build

- uses: actions/checkout@v2
- uses: actions/checkout@v4

- run: make

- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
with:
name: 'sysext'
path: 'sysext.raw'
Expand All @@ -26,25 +26,34 @@ jobs:

runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v4
with:
name: 'sysext'

- id: release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- run: |
repository="${{ github.repository }}"
repository_name="${repository#*/}"
package_name="${repository_name#*-}"
mv sysext.raw "${package_name}-${{ github.ref_name }}.raw"
sha256sum *.raw > SHA256SUMS
cat << EOF > "${package_name}.conf"
[Transfer]
Verify=false
[Source]
Type=url-file
Path=https://github.com/${{ github.repository }}/releases/latest/download/
MatchPattern=${package_name}[email protected]
[Target]
InstancesMax=3
Type=regular-file
Path=/opt/extensions/${package_name}
CurrentSymlink=/etc/extensions/${package_name}.raw
EOF
- uses: softprops/action-gh-release@v1
with:
tag_name: ${{ github.ref_name }}
release_name: Release ${{ github.ref_name }}
draft: false
prerelease: false

- uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.release.outputs.upload_url }}
asset_name: 'qemu-ga-${{ github.ref_name }}.raw'
asset_path: 'sysext.raw'
asset_content_type: application/octet-stream
name: Release ${{ github.ref_name }}
files: |
SHA256SUMS
*.raw
*.conf

0 comments on commit 7cc94c8

Please sign in to comment.