Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes to CI build workflows for dev, staging and production pipelines into feature/evm #1906

Merged
merged 22 commits into from
Apr 21, 2023
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
046d9a2
Enable aarch64-apple-darwin builds (#1893) (#1894)
sieniven Apr 13, 2023
f79e25a
CI workflow fixes for dev, staging and production pipelines
sieniven Apr 13, 2023
09c502f
Fix naming bug
sieniven Apr 13, 2023
dde9537
Removed publishing to dockerhub pipeline in build staging workflow, a…
sieniven Apr 13, 2023
0e5b509
Added workflow to push arm build image into Dockerhub. Rename docker …
sieniven Apr 13, 2023
7d8aaec
Fix docker tags
sieniven Apr 13, 2023
fa56172
Reverting changes to pushing only linux-x64 into dockerhub registry.
sieniven Apr 18, 2023
b980638
Include image layer to install rust dependencies
sieniven Apr 18, 2023
3ad2ff7
Install protobuf-compiler pkg dep
sieniven Apr 18, 2023
506d8fa
bug fixes
sieniven Apr 18, 2023
95b53c6
Fix bug in pkg_local_ensure_osx_sysroot function that does not exit o…
sieniven Apr 15, 2023
b154628
Install target toolchains in dockerfiles
sieniven Apr 18, 2023
31ff90f
Fix target toolchain for linux-arm docker build
sieniven Apr 18, 2023
1a946dc
Resolve rustc toolchain bug
sieniven Apr 18, 2023
d9dc3c2
Removed optional label in proto3 syntax to fix build error
sieniven Apr 19, 2023
6915a71
Merge branch 'feature/evm' into niven/evm-ci-fix
sieniven Apr 20, 2023
cbc32c9
Fix _tar func in make.sh to pass all args to gnu-tar, and fix docker …
sieniven Apr 21, 2023
9445b8c
Re-order build targets to select major dev envs first.
sieniven Apr 21, 2023
123a8c2
Merge branch 'feature/evm' into niven/evm-ci-fix
sieniven Apr 21, 2023
d1ecf6d
Fix merge errors
sieniven Apr 21, 2023
2f38b99
Revert to feature/evm branch version
sieniven Apr 21, 2023
ca4be69
Reverting eth.proto version to feature/evm version
sieniven Apr 21, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 1 addition & 18 deletions .github/workflows/build-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,23 +45,6 @@ jobs:
docker tag defichain-x86_64-pc-linux-gnu:${ver} defi/defichain:${ver}
docker push defi/defichain:${ver}

linux-armhf:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Populate environment
run: GIT_VERSION=1 ./make.sh ci-export-vars

- name: Build and package
run: GIT_VERSION=1 TARGET="arm-linux-gnueabihf" ./make.sh docker-release

- name: Publish artifact - arm-linux-gnueabihf
uses: actions/upload-artifact@v3
with:
name: defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf
path: ./build/defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf.tar.gz

win-x64:
runs-on: ubuntu-latest
steps:
Expand All @@ -79,7 +62,7 @@ jobs:
name: defichain-${{ env.BUILD_VERSION }}-x86_64-w64-mingw32
path: ./build/defichain-${{ env.BUILD_VERSION }}-x86_64-w64-mingw32.tar.gz

mac-x64:
osx-x64:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down
166 changes: 153 additions & 13 deletions .github/workflows/build-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ env:
DOCKER_HUB_USER: defi

jobs:
linux:
linux-x64:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

Expand Down Expand Up @@ -42,8 +42,60 @@ jobs:
docker tag defichain-x86_64-pc-linux-gnu:${ver} defi/defichain:${tag}
done
docker push defi/defichain:${ver}

linux-armhf:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

steps:
- uses: actions/checkout@v3

- name: Populate environment
run: GIT_VERSION=1 ./make.sh ci-export-vars

- name: Build and package
run: GIT_VERSION=1 TARGET="arm-linux-gnueabihf" ./make.sh docker-release

windows:
- name: Publish artifact - arm-linux-gnueabihf
uses: actions/upload-artifact@v3
with:
name: defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf
path: ./build/defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf.tar.gz

- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ env.DOCKER_HUB_USER }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}

- name: Push to Docker Hub
run: |
sieniven marked this conversation as resolved.
Show resolved Hide resolved
set -e; ver=${{ env.BUILD_VERSION }}
for tag in $(echo $ver latest); do
docker tag defichain-arm-linux-gnueabihf:${ver} defi/defichain:${tag}
done
docker push defi/defichain:${ver}

linux-aarch64:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

steps:
- uses: actions/checkout@v3

- name: Populate environment
run: GIT_VERSION=1 ./make.sh ci-export-vars

- name: Build and package
run: GIT_VERSION=1 TARGET="aarch64-linux-gnu" ./make.sh docker-release

- name: Publish artifact - aarch64-linux-gnu
uses: actions/upload-artifact@v3
with:
name: defichain-${{ env.BUILD_VERSION }}-aarch64-linux-gnu
path: ./build/defichain-${{ env.BUILD_VERSION }}-aarch64-linux-gnu.tar.gz

win-x64:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

Expand All @@ -62,7 +114,7 @@ jobs:
name: defichain-${{ env.BUILD_VERSION }}-x86_64-w64-mingw32
path: ./build/defichain-${{ env.BUILD_VERSION }}-x86_64-w64-mingw32.tar.gz

macos:
osx-x64:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

Expand All @@ -81,11 +133,33 @@ jobs:
name: defichain-${{ env.BUILD_VERSION }}-x86_64-apple-darwin
path: ./build/defichain-${{ env.BUILD_VERSION }}-x86_64-apple-darwin.tar.gz

osx-aarch64:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

steps:
- uses: actions/checkout@v3

- name: Populate environment
run: GIT_VERSION=1 ./make.sh ci-export-vars

- name: Build and package
run: GIT_VERSION=1 TARGET="aarch64-apple-darwin" ./make.sh docker-release

- name: Publish artifact - aarch64-apple-darwin
uses: actions/upload-artifact@v3
with:
name: defichain-${{ env.BUILD_VERSION }}-aarch64-apple-darwin
path: ./build/defichain-${{ env.BUILD_VERSION }}-aarch64-apple-darwin.tar.gz

create-release:
needs:
- linux
- windows
- macos
- linux-x64
- linux-armhf
- linux-aarch64
- win-x64
- osx-x64
- osx-aarch64
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')

Expand All @@ -101,7 +175,7 @@ jobs:
- name: Get artifacts
uses: actions/download-artifact@v3

- name: zip package for windows
- name: zip package for win-x64
run: |
set -e; ver=${{ env.BUILD_VERSION }}
cd defichain-${ver}-x86_64-w64-mingw32
Expand All @@ -121,12 +195,18 @@ jobs:
set -e; ver=${{ env.BUILD_VERSION }}
cd ./defichain-${ver}-x86_64-pc-linux-gnu
sha256sum ./defichain-${ver}-x86_64-pc-linux-gnu.tar.gz > ./defichain-${ver}-x86_64-pc-linux-gnu.tar.gz.SHA256
cd ./defichain-${ver}-arm-linux-gnueabihf
sha256sum ./defichain-${ver}-arm-linux-gnueabihf.tar.gz > ./defichain-${ver}-arm-linux-gnueabihf.tar.gz.SHA256
cd ./defichain-${ver}-aarch64-linux-gnu
sha256sum ./defichain-${ver}-aarch64-linux-gnu.tar.gz > ./defichain-${ver}-aarch64-linux-gnu.tar.gz.SHA256
cd .. && cd ./defichain-${ver}-x86_64-w64-mingw32
sha256sum ./defichain-${ver}-x86_64-w64-mingw32.zip > ./defichain-${ver}-x86_64-w64-mingw32.zip.SHA256
cd .. && cd ./defichain-${ver}-x86_64-apple-darwin
sha256sum ./defichain-${ver}-x86_64-apple-darwin.tar.gz > ././defichain-${ver}-x86_64-apple-darwin.tar.gz.SHA256
cd .. && cd ./defichain-${ver}-aarch64-apple-darwin
sha256sum ./defichain-${ver}-aarch64-apple-darwin.tar.gz > ././defichain-${ver}-aarch64-apple-darwin.tar.gz.SHA256

- name: Upload release asset - linux
- name: Upload release asset - linux-x64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -136,7 +216,7 @@ jobs:
asset_name: defichain-${{ env.BUILD_VERSION }}-x86_64-pc-linux-gnu.tar.gz
asset_content_type: application/gzip

- name: Upload checksum - linux
- name: Upload checksum - linux-x64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -145,8 +225,48 @@ jobs:
asset_path: ./defichain-${{ env.BUILD_VERSION }}-x86_64-pc-linux-gnu/defichain-${{ env.BUILD_VERSION }}-x86_64-pc-linux-gnu.tar.gz.SHA256
asset_name: defichain-${{ env.BUILD_VERSION }}-x86_64-pc-linux-gnu.tar.gz.SHA256
asset_content_type: text/plain

- name: Upload release asset - linux-armhf
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.get_release_by_tag.outputs.upload_url }}
asset_path: ./defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf/defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf.tar.gz
asset_name: defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf.tar.gz
asset_content_type: application/gzip

- name: Upload checksum - linux-armhf
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.get_release_by_tag.outputs.upload_url }}
asset_path: ./defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf/defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf.tar.gz.SHA256
asset_name: defichain-${{ env.BUILD_VERSION }}-arm-linux-gnueabihf.tar.gz.SHA256
asset_content_type: text/plain

- name: Upload release asset - linux-aarch64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.get_release_by_tag.outputs.upload_url }}
asset_path: ./defichain-${{ env.BUILD_VERSION }}-aarch64-linux-gnu/defichain-${{ env.BUILD_VERSION }}-aarch64-linux-gnu.tar.gz
asset_name: defichain-${{ env.BUILD_VERSION }}-aarch64-linux-gnu.tar.gz
asset_content_type: application/gzip

- name: Upload checksum - linux-aarch64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.get_release_by_tag.outputs.upload_url }}
asset_path: ./defichain-${{ env.BUILD_VERSION }}-aarch64-linux-gnu/defichain-${{ env.BUILD_VERSION }}-aarch64-linux-gnu.tar.gz.SHA256
asset_name: defichain-${{ env.BUILD_VERSION }}-aarch64-linux-gnu.tar.gz.SHA256
asset_content_type: text/plain

- name: Upload release asset - windows
- name: Upload release asset - win-x64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -156,7 +276,7 @@ jobs:
asset_name: defichain-${{ env.BUILD_VERSION }}-x86_64-w64-mingw32.zip
asset_content_type: application/zip

- name: Upload checksum asset - windows
- name: Upload checksum asset - win-x64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -166,7 +286,7 @@ jobs:
asset_name: defichain-${{ env.BUILD_VERSION }}-x86_64-w64-mingw32.zip.SHA256
asset_content_type: text/plain

- name: Upload release asset - macos
- name: Upload release asset - osx-x64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -176,7 +296,7 @@ jobs:
asset_name: defichain-${{ env.BUILD_VERSION }}-x86_64-apple-darwin.tar.gz
asset_content_type: application/gzip

- name: Upload checksum asset - macos
- name: Upload checksum asset - osx-x64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -185,3 +305,23 @@ jobs:
asset_path: ./defichain-${{ env.BUILD_VERSION }}-x86_64-apple-darwin/defichain-${{ env.BUILD_VERSION }}-x86_64-apple-darwin.tar.gz.SHA256
asset_name: defichain-${{ env.BUILD_VERSION }}-x86_64-apple-darwin.tar.gz.SHA256
asset_content_type: text/plain

- name: Upload release asset - osx-aarch64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.get_release_by_tag.outputs.upload_url }}
asset_path: ./defichain-${{ env.BUILD_VERSION }}-aarch64-apple-darwin/defichain-${{ env.BUILD_VERSION }}-aarch64-apple-darwin.tar.gz
asset_name: defichain-${{ env.BUILD_VERSION }}-aarch64-apple-darwin.tar.gz
asset_content_type: application/gzip

- name: Upload checksum asset - osx-aarch64
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.get_release_by_tag.outputs.upload_url }}
asset_path: ./defichain-${{ env.BUILD_VERSION }}-aarch64-apple-darwin/defichain-${{ env.BUILD_VERSION }}-aarch64-apple-darwin.tar.gz.SHA256
asset_name: defichain-${{ env.BUILD_VERSION }}-aarch64-apple-darwin.tar.gz.SHA256
asset_content_type: text/plain
Loading