-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add musl build target and upload artifact to cos
- Loading branch information
1 parent
06158e5
commit b9eb3d3
Showing
1 changed file
with
122 additions
and
8 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 |
---|---|---|
|
@@ -87,7 +87,6 @@ jobs: | |
retry_times: 5 | ||
storage_class: "STANDARD" | ||
|
||
|
||
linux-arm64-build-job: | ||
runs-on: aws-arm64-runner | ||
steps: | ||
|
@@ -147,19 +146,19 @@ jobs: | |
region: ap-shanghai | ||
retry_times: 5 | ||
storage_class: "STANDARD" | ||
|
||
|
||
darwin-x86-build-job: | ||
runs-on: macos-latest | ||
steps: | ||
# GitHub Hosted MacOS runner cannot connect to time.apple.com, so use time.windows.com | ||
- name: Sync System Time | ||
run: | | ||
set +e; | ||
for i in {1..10}; do | ||
sudo sntp -sS time.windows.com; | ||
if [ "$?" == "0" ]; then | ||
if sudo sntp -sS time.windows.com; then | ||
exit 0; | ||
fi | ||
sleep 1; | ||
done | ||
exit 1; | ||
- name: Checkout source | ||
|
@@ -187,6 +186,7 @@ jobs: | |
p12-file-base64: ${{ secrets.APPLE_DEVELOPER_CERTIFICATE_P12_BASE64 }} | ||
# The password used to import the PKCS12 file. | ||
p12-password: ${{ secrets.APPLE_DEVELOPER_CERTIFICATE_PASSWORD }} | ||
|
||
- name: Clone gon | ||
uses: actions/checkout@v4 | ||
with: | ||
|
@@ -200,6 +200,7 @@ jobs: | |
make; | ||
chmod +x gon; | ||
echo "$(pwd)" >> $GITHUB_PATH; | ||
- name: Code signing and app notarization | ||
env: | ||
AC_PASSWORD: ${{ secrets.AC_PASSWORD }} | ||
|
@@ -264,19 +265,17 @@ jobs: | |
INPUT_SECRET_KEY: ${{ secrets.TENCENT_SK }} | ||
INPUT_STORAGE_CLASS: "STANDARD" | ||
|
||
|
||
#if the release for darwin-arm is failed, please contact guguducken to check runner status | ||
darwin-arm-build-job: | ||
runs-on: mac-arm64-mini | ||
steps: | ||
- name: Sync system time | ||
run: | | ||
set +e; | ||
for i in {1..10}; do | ||
sudo sntp -sS time.apple.com; | ||
if [ "$?" == "0" ]; then | ||
if sudo sntp -sS time.apple.com; then | ||
exit 0; | ||
fi | ||
sleep 1; | ||
done | ||
exit 1; | ||
- name: Checkout source | ||
|
@@ -373,3 +372,118 @@ jobs: | |
run: | | ||
security list-keychains | grep sign | awk 'system("security delete-keychain "$1)' | ||
security find-identity -p codesigning | grep ID | awk 'NR=1{system("security delete-identity -Z "$2)}' | ||
musl-x86-build-job: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: Checkout source | ||
uses: actions/checkout@v4 | ||
- name: Get release | ||
id: get_release | ||
uses: bruceadams/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.TOKEN_ACTION }} | ||
- name: Echo some info | ||
run: | | ||
echo ${{ steps.get_release.outputs.upload_url }} | ||
echo ${{ steps.get_release.outputs.tag_name }} | ||
- name: Set up Go | ||
uses: matrixorigin/CI/actions/setup-env@main | ||
with: | ||
setup-java: false | ||
- name: Build normal | ||
run: | | ||
cd $GITHUB_WORKSPACE; | ||
make musl; | ||
# copy toml configure file | ||
mkdir -p mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64/etc | ||
mv mo-service mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64/ | ||
mv ./etc/launch mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64/etc/ | ||
if [ -d "./etc/launch-with-python-udf-server" ]; then | ||
mv ./etc/launch-with-python-udf-server ./mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64/etc/ | ||
fi | ||
if [ -d "./pkg/udf/pythonservice/pyserver" ]; then | ||
mkdir -p mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64/pkg/udf/pythonservice | ||
mv ./pkg/udf/pythonservice/pyserver ./mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64/pkg/udf/pythonservice | ||
fi | ||
zip -r mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64.zip mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64 | ||
- name: Upload Release normal musl x86_64 | ||
uses: actions/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.TOKEN_ACTION }} | ||
with: | ||
upload_url: ${{ steps.get_release.outputs.upload_url }} | ||
asset_path: ./mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64.zip | ||
asset_name: mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64.zip | ||
asset_content_type: application/zip | ||
- name: Upload Artifact to COS | ||
uses: matrixorigin/CI/actions/upload-artifact-oss@main | ||
with: | ||
access_key: ${{ secrets.TENCENT_AK }} | ||
secret_key: ${{ secrets.TENCENT_SK }} | ||
artifact_path: ${{ github.workspace }}/mo-${{ steps.get_release.outputs.tag_name }}-musl-x86_64.zip | ||
bucket: ${{ secrets.RELEASE_BUCKET }} | ||
oss_path: matrixone/${{ steps.get_release.outputs.tag_name }} | ||
provider: cos | ||
region: ap-shanghai | ||
retry_times: 5 | ||
storage_class: "STANDARD" | ||
|
||
|
||
musl-arm64-build-job: | ||
runs-on: aws-arm64-runner | ||
steps: | ||
- name: Checkout source | ||
uses: actions/checkout@v4 | ||
- name: Get release | ||
id: get_release | ||
uses: bruceadams/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.TOKEN_ACTION }} | ||
- name: Echo some info | ||
run: | | ||
echo ${{ steps.get_release.outputs.upload_url }} | ||
echo ${{ steps.get_release.outputs.tag_name }} | ||
- name: Set up Go | ||
uses: matrixorigin/CI/actions/setup-env@main | ||
with: | ||
setup-java: false | ||
- name: Build normal | ||
run: | | ||
cd $GITHUB_WORKSPACE; | ||
make musl; | ||
# copy toml configure file | ||
mkdir -p mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64/etc | ||
mv mo-service mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64/ | ||
mv ./etc/launch mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64/etc/ | ||
if [ -d "./etc/launch-with-python-udf-server" ]; then | ||
mv ./etc/launch-with-python-udf-server ./mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64/etc/ | ||
fi | ||
if [ -d "./pkg/udf/pythonservice/pyserver" ]; then | ||
mkdir -p mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64/pkg/udf/pythonservice | ||
mv ./pkg/udf/pythonservice/pyserver ./mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64/pkg/udf/pythonservice | ||
fi | ||
zip -r mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64.zip mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64 | ||
- name: Upload Release normal musl arm64 | ||
uses: actions/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.TOKEN_ACTION }} | ||
with: | ||
upload_url: ${{ steps.get_release.outputs.upload_url }} | ||
asset_path: ./mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64.zip | ||
asset_name: mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64.zip | ||
asset_content_type: application/zip | ||
- name: Upload Artifact to COS | ||
uses: matrixorigin/CI/actions/upload-artifact-oss@main | ||
with: | ||
access_key: ${{ secrets.TENCENT_AK }} | ||
secret_key: ${{ secrets.TENCENT_SK }} | ||
artifact_path: ${{ github.workspace }}/mo-${{ steps.get_release.outputs.tag_name }}-musl-arm64.zip | ||
bucket: ${{ secrets.RELEASE_BUCKET }} | ||
oss_path: matrixone/${{ steps.get_release.outputs.tag_name }} | ||
provider: cos | ||
region: ap-shanghai | ||
retry_times: 5 | ||
storage_class: "STANDARD" |