-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* ci: add release job * fix: apply review * chore: rename task and remove needs build_share_library * fix: add needs * fix: remove needs * fix: rename task * modify Dockerfile.alpine * fix: format error * chore: update setup-go and go-version * chore: fix go version
- Loading branch information
1 parent
7adc3a0
commit f554eec
Showing
5 changed files
with
89 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -134,6 +134,21 @@ jobs: | |
name: libwasmvm | ||
path: ./api/libwasmvm.x86_64.so | ||
|
||
build_static_lib: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: set up | ||
uses: actions/[email protected] | ||
with: | ||
go-version: 1.18 | ||
id: go | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Build docker image | ||
run: cd builders && make docker-image-alpine | ||
- name: Build & Test static library | ||
run: make release-build-alpine | ||
|
||
test: | ||
needs: build_shared_library | ||
runs-on: ubuntu-latest | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,6 +34,39 @@ jobs: | |
run: | | ||
VERSION=$(cargo tree -i wasmvm | grep -oE "[0-9]+(\.[0-9]+){2}-[0-9]+(\.[0-9]+){2}") | ||
echo ::set-output name=version::v$VERSION | ||
build_static_lib: | ||
name: Build static libraries | ||
needs: | ||
- get-version | ||
if: ${{ needs.get-version.outputs.package-version != needs.get-version.outputs.latest-tag }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: set up | ||
uses: actions/[email protected] | ||
with: | ||
go-version: 1.18 | ||
id: go | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Build docker image | ||
run: cd builders && make docker-image-alpine | ||
- name: Build & Test static library | ||
run: make release-build-alpine | ||
- name: Collect artifacts | ||
run: | | ||
mkdir artifacts | ||
cp ./api/libwasmvm_muslc.a artifacts/libwasmvm_muslc.x86_64.a | ||
cp ./api/libwasmvm_muslc.aarch64.a artifacts/libwasmvm_muslc.aarch64.a | ||
- name: Create checksums | ||
working-directory: artifacts | ||
run: sha256sum * > checksums.txt && cat checksums.txt | ||
- name: Upload static library | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: artifacts | ||
path: ./artifacts | ||
|
||
push-tag: # if the version does not exist as git tag, push it | ||
name: Push Tag | ||
needs: | ||
|
@@ -46,3 +79,21 @@ jobs: | |
curl -s -H "Authorization: token ${GITHUB_TOKEN}" \ | ||
-d "{\"ref\": \"refs/tags/${{ needs.get-version.outputs.package-version }}\", \"sha\": \"${GITHUB_SHA}\"}" \ | ||
"https://api.github.com/repos/${GITHUB_REPOSITORY}/git/refs" | ||
update-releases: | ||
name: Update Latest release | ||
needs: | ||
- push-tag | ||
- build_static_lib | ||
if: ${{ needs.get-version.outputs.package-version != needs.get-version.outputs.latest-tag }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Create Release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
tag_name: ${{ needs.get-version.outputs.package-version }} | ||
body: ${{ github.event.pull_request.body }} | ||
files: | | ||
./artifacts/* | ||
draft: false | ||
prerelease: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters