From 1a0d5f97862932c74b14c761dc01adba65675738 Mon Sep 17 00:00:00 2001 From: ian Date: Mon, 21 Jun 2021 20:15:32 +0800 Subject: [PATCH 1/5] ci: setup GitHub Actions --- .github/workflows/ci.yaml | 71 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 .github/workflows/ci.yaml diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 00000000..e590fed4 --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,71 @@ +name: CI workflow + +on: + pull_request: + types: [ opened, synchronize, reopened ] + push: + branches: + - "develop" + - "master" + - "pkg/*" + +env: + CARGO_TERM_COLOR: always + RUST_BACKTRACE: full + +jobs: + unit-test: + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ ubuntu-latest, macos-latest, windows-latest ] + steps: + - uses: actions/checkout@v2 + - name: UnitTest + run: make test + + integration-test: + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest] + steps: + - uses: actions/checkout@v2 + - name: Integration_Test + run: make integration + + linters: + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest] + steps: + - uses: actions/checkout@v2 + - name: Linters + run: | + cargo fmt --version || rustup component add rustfmt + cargo clippy --version || rustup component add clippy + make fmt + make clippy + git diff --exit-code Cargo.lock + + security-audit: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Security Audit & Licenses + run: | + rustup toolchain install nightly --allow-downgrade --profile minimal + make security-audit + + ci-success: + name: ci + needs: + - unit-test + - integration-test + - linters + - security-audit + runs-on: ubuntu-latest + steps: + - name: CI succeeded + run: exit 0 From c0b0154cdceb27576a25ac32e422a27dec95947a Mon Sep 17 00:00:00 2001 From: ian Date: Mon, 21 Jun 2021 20:44:36 +0800 Subject: [PATCH 2/5] ci: enable clang for Windows --- .github/workflows/ci.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index e590fed4..8ad72fe0 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -21,6 +21,13 @@ jobs: os: [ ubuntu-latest, macos-latest, windows-latest ] steps: - uses: actions/checkout@v2 + - if: matrix.os == 'windows-latest' + name: Windows Dependencies + run: | + Set-ExecutionPolicy RemoteSigned -scope CurrentUser + Invoke-Expression (New-Object System.Net.WebClient).DownloadString('https://get.scoop.sh') + scoop install yasm + echo ("PATH=" + $env:PATH + ";" + $env:USERPROFILE + "\scoop\shims;C:\msys64\mingw64\bin") >> $env:GITHUB_ENV - name: UnitTest run: make test From 604c1e75b91895958546402d46256e8342abb707 Mon Sep 17 00:00:00 2001 From: ian Date: Tue, 22 Jun 2021 10:16:34 +0800 Subject: [PATCH 3/5] ci: add workflow to create release binaries --- .github/workflows/package.yaml | 235 ++++++++++++++++++++++++++++++ devtools/ci/package.sh | 13 +- devtools/ci/signer.asc.gpg | Bin 0 -> 4918 bytes devtools/ci/travis-secret.asc.enc | Bin 9824 -> 0 bytes 4 files changed, 238 insertions(+), 10 deletions(-) create mode 100644 .github/workflows/package.yaml create mode 100644 devtools/ci/signer.asc.gpg delete mode 100644 devtools/ci/travis-secret.asc.enc diff --git a/.github/workflows/package.yaml b/.github/workflows/package.yaml new file mode 100644 index 00000000..ded4dbdd --- /dev/null +++ b/.github/workflows/package.yaml @@ -0,0 +1,235 @@ +name: Package + +on: + push: + branches: + - 'pkg/*' + +env: + CARGO_TERM_COLOR: always + RUST_BACKTRACE: full + +jobs: + create-release: + name: Create release + runs-on: ubuntu-latest + outputs: + upload_url: ${{ steps.create-release.outputs.upload_url }} + steps: + - uses: actions/checkout@v2 + - name: Set tag + run: | + export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` + echo "GIT_TAG_NAME=$GIT_TAG_NAME" >> $GITHUB_ENV + - name: Create release + id: create-release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ env.GIT_TAG_NAME}} + release_name: ${{ env.GIT_TAG_NAME}} + draft: true + prerelease: true + + package-for-linux: + name: package-for-linux + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Set Env + run: | + export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` + echo "GIT_TAG_NAME=$GIT_TAG_NAME" >> $GITHUB_ENV + - name: Build CKB and Package ckb-cli + env: + LARGE_SECRET_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} + GPG_SIGNER: ${{ secrets.GPG_SIGNER }} + run: | + export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` + mkdir -p $HOME/.cargo + docker run --rm -i -w /ckb-cli -v $(pwd):/ckb-cli -v $HOME/.cargo:/root/.cargo -e OPENSSL_STATIC=1 -e OPENSSL_LIB_DIR=/usr/local/lib -e OPENSSL_INCLUDE_DIR=/usr/local/include/openssl $BUILDER_IMAGE make prod + gpg --quiet --batch --yes --decrypt --passphrase="$LARGE_SECRET_PASSPHRASE" --output devtools/ci/signer.asc devtools/ci/signer.asc.gpg + gpg --import devtools/ci/signer.asc + devtools/ci/package.sh target/release/ckb-cli + mv ${{ github.workspace }}/releases/ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} ${{ github.workspace }} + mv ${{ github.workspace }}/releases/ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc ${{ github.workspace }} + - name: upload-zip-file + uses: actions/upload-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} + path: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} + - name: upload-asc-file + uses: actions/upload-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc + path: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc + env: + BUILDER_IMAGE: nervos/ckb-docker-builder:xenial-rust-1.51.0 + REL_PKG: x86_64-unknown-linux-gnu.tar.gz + + package-for-centos: + name: package-for-centos + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Set Env + run: | + export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` + echo "GIT_TAG_NAME=$GIT_TAG_NAME" >> $GITHUB_ENV + - name: Build CKB and Package ckb-cli + env: + LARGE_SECRET_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} + GPG_SIGNER: ${{ secrets.GPG_SIGNER }} + run: | + export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` + mkdir -p $HOME/.cargo + docker run --rm -i -w /ckb-cli -v $(pwd):/ckb-cli -v $HOME/.cargo:/root/.cargo $BUILDER_IMAGE scl enable llvm-toolset-7 'make prod' + gpg --quiet --batch --yes --decrypt --passphrase="$LARGE_SECRET_PASSPHRASE" --output devtools/ci/signer.asc devtools/ci/signer.asc.gpg + gpg --import devtools/ci/signer.asc + devtools/ci/package.sh target/release/ckb-cli + mv ${{ github.workspace }}/releases/ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} ${{ github.workspace }} + mv ${{ github.workspace }}/releases/ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc ${{ github.workspace }} + - name: upload-zip-file + uses: actions/upload-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} + path: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} + - name: upload-asc-file + uses: actions/upload-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc + path: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc + env: + BUILDER_IMAGE: nervos/ckb-docker-builder:centos-7-rust-1.51.0 + REL_PKG: x86_64-unknown-centos-gnu.tar.gz + + package-for-mac: + name: package-for-mac + runs-on: macos-latest + steps: + - uses: actions/checkout@v2 + - name: Set Env + run: | + export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` + echo "GIT_TAG_NAME=$GIT_TAG_NAME" >> $GITHUB_ENV + - name: Build CKB and Package ckb-cli + env: + LARGE_SECRET_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} + GPG_SIGNER: ${{ secrets.GPG_SIGNER }} + run: | + export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` + make OPENSSL_STATIC=1 OPENSSL_LIB_DIR=/usr/local/opt/openssl@1.1/lib OPENSSL_INCLUDE_DIR=/usr/local/opt/openssl@1.1/include prod + gpg --quiet --batch --yes --decrypt --passphrase="$LARGE_SECRET_PASSPHRASE" --output devtools/ci/signer.asc devtools/ci/signer.asc.gpg + gpg --import devtools/ci/signer.asc + devtools/ci/package.sh target/release/ckb-cli + mv ${{ github.workspace }}/releases/ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} ${{ github.workspace }} + mv ${{ github.workspace }}/releases/ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc ${{ github.workspace }} + - name: upload-zip-file + uses: actions/upload-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} + path: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} + - name: upload-asc-file + uses: actions/upload-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc + path: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc + env: + REL_PKG: x86_64-apple-darwin.zip + + package-for-windows: + name: package-for-windows + runs-on: windows-latest + steps: + - name: Install Dependencies + run: | + Set-ExecutionPolicy RemoteSigned -scope CurrentUser + Invoke-Expression (New-Object System.Net.WebClient).DownloadString('https://get.scoop.sh') + scoop install yasm + echo ("GIT_TAG_NAME=" + $env:GITHUB_REF.replace('refs/heads/pkg/', '')) >> $env:GITHUB_ENV + echo ("PATH=" + $env:PATH + ";" + $env:USERPROFILE + "\scoop\shims;C:\msys64\mingw64\bin") >> $env:GITHUB_ENV + - uses: actions/checkout@v2 + - name: Build + run: | + make prod + - name: Prepare archive + run: | + $env:GIT_TAG_NAME=($env:GITHUB_REF -split '/')[3] + mkdir ckb-cli_$($env:GIT_TAG_NAME)_x86_64-pc-windows-msvc + cp -r target/release/ckb-cli.exe,README.md,CHANGELOG.md,COPYING ckb-cli_$($env:GIT_TAG_NAME)_x86_64-pc-windows-msvc + - name: Archive Files + run: | + $env:GIT_TAG_NAME=($env:GITHUB_REF -split '/')[3] + Compress-Archive -Path ckb-cli_$($env:GIT_TAG_NAME)_x86_64-pc-windows-msvc -DestinationPath ckb-cli_$($env:GIT_TAG_NAME)_$($env:REL_PKG) + - name: Sign Archive + env: + LARGE_SECRET_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} + GPG_SIGNER: ${{ secrets.GPG_SIGNER }} + run: | + $CYGPWD = cygpath -u (Get-Location) + gpg --quiet --batch --yes --decrypt --passphrase="$env:LARGE_SECRET_PASSPHRASE" --output "$CYGPWD/devtools/ci/signer.asc" "$CYGPWD/devtools/ci/signer.asc.gpg" + gpg --import "$CYGPWD/devtools/ci/signer.asc" + $env:GIT_TAG_NAME=($env:GITHUB_REF -split '/')[3] + gpg -u "$env:GPG_SIGNER" -ab "$CYGPWD/ckb-cli_$($env:GIT_TAG_NAME)_$($env:REL_PKG)" + - name: upload-artifact + uses: actions/upload-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} + path: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }} + - name: upload-artifact + uses: actions/upload-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc + path: ckb-cli_${{env.GIT_TAG_NAME }}_${{env.REL_PKG }}.asc + env: + REL_PKG: x86_64-pc-windows-msvc.zip + + Upload_File: + name: Upload_Zip_File + runs-on: ubuntu-latest + strategy: + matrix: + include: + - REL_PKG: x86_64-unknown-linux-gnu.tar.gz + - REL_PKG: x86_64-unknown-centos-gnu.tar.gz + - REL_PKG: x86_64-apple-darwin.zip + - REL_PKG: x86_64-pc-windows-msvc.zip + needs: + - create-release + - package-for-linux + - package-for-mac + - package-for-windows + - package-for-centos + steps: + - uses: actions/checkout@v2 + - name: Set tag + run: | + export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` + echo "GIT_TAG_NAME=$GIT_TAG_NAME" >> $GITHUB_ENV + - name: Prepare - Download tar + uses: actions/download-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME}}_${{ matrix.REL_PKG }} + - name: Prepare - Download asc + uses: actions/download-artifact@v2 + with: + name: ckb-cli_${{env.GIT_TAG_NAME}}_${{ matrix.REL_PKG }}.asc + - name: Upload tar assets + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ needs.create-release.outputs.upload_url }} + asset_name: ckb-cli_${{env.GIT_TAG_NAME}}_${{ matrix.REL_PKG }} + asset_path: ${{ github.workspace }}/ckb-cli_${{env.GIT_TAG_NAME }}_${{ matrix.REL_PKG }} + asset_content_type: application/octet-stream + - name: Upload asc assets + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ needs.create-release.outputs.upload_url }} + asset_name: ckb-cli_${{env.GIT_TAG_NAME}}_${{ matrix.REL_PKG }}.asc + asset_path: ${{ github.workspace }}/ckb-cli_${{env.GIT_TAG_NAME }}_${{ matrix.REL_PKG }}.asc + asset_content_type: application/octet-stream diff --git a/devtools/ci/package.sh b/devtools/ci/package.sh index 97cd11ad..033272b9 100755 --- a/devtools/ci/package.sh +++ b/devtools/ci/package.sh @@ -1,13 +1,7 @@ #!/bin/bash set -eu -if [ -z "${TRAVIS_TAG:-}" ]; then - if [ -n "${TRAVIS_BRANCH}" ]; then - TRAVIS_TAG="${TRAVIS_BRANCH##*/}" - else - TRAVIS_TAG="$(git describe)" - fi -fi +GIT_TAG_NAME="${GIT_TAG_NAME:-"$(git describe)"}" if [ -z "${REL_PKG:-}" ]; then if [ "$(uname)" = Darwin ]; then REL_PKG=x86_64-apple-darwin.zip @@ -16,9 +10,8 @@ if [ -z "${REL_PKG:-}" ]; then fi fi -PKG_NAME="ckb-cli_${TRAVIS_TAG}_${REL_PKG%%.*}" -ARCHIVE_NAME="ckb-cli_${TRAVIS_TAG}_${REL_PKG}" - +PKG_NAME="ckb-cli_${GIT_TAG_NAME}_${REL_PKG%%.*}" +ARCHIVE_NAME="ckb-cli_${GIT_TAG_NAME}_${REL_PKG}" echo "ARCHIVE_NAME=$ARCHIVE_NAME" rm -rf releases diff --git a/devtools/ci/signer.asc.gpg b/devtools/ci/signer.asc.gpg new file mode 100644 index 0000000000000000000000000000000000000000..af2311d68be9c212df9f41e168b71d9497450056 GIT binary patch literal 4918 zcmV-66Upq14Fm}T0`M-94tTA&)Bn=!0nD+8JNVU8oQozmOFv~9evw$1)5c;QNjT}p&>BvhMMMRB;$?+s* zC&04p;B+DB#hMA4vWihU+mz?tFdZs)j+>zDoVZcih=ZE!6tp;wl(4xsfW9_~h67H{ac$N<1WDJ%=se(Nc?wY|L%#zIA7JcoSPg5w5P- zn;VeMcq2R;DD6Y5*q?4}tq5*PH}nvuSMU|RJ`tIwQgM8KE|US}{2Aui^iMUPr(W`O zyEwDvr3FqKn(RZ2dx)!NgSs+#bsIygX|2JCL70V*V8RVh&T*SOpRw6(V@ruU%dTLm ze7t=3L=nmt9w}udBAU`DmQXWXvo|;tGpZ+-Y!^LKY;sB3>H6pg9IW+aR2ux8Bv}V8 z0FptWAeYk-N(Gnwb|1lz_3lXk20CpT9+Q8-+Zl^do-b&0TPYF6B2#JdCRH9ZPbYDs zzI?U5^0wo)eo6S92%H5V<{c(fJgbCNeE;Phz?5+B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@pP8^7Q2DD@`(N?3H?aY9&<`ReoaFCqUZW_6pRkaFwA@#+a9cS!!ECLk zBA^g;`mswG|Meh7V#lGda}Bp4uoz?x>za_@2Y6edEH^;~b7xsyhvl-*Y^sxupj!~X z1{DL!{^B$?1;-zbz>3V2dqYpESgG{xNrW?az9U3<3*V1MoulCefuoPKrdtC-mBuC2 zB83e`${HUXej@2bx)?hM$-gqz`smqeApZ6fw)rvGcS|Cl;a*!uf7gVH@Ky6c>m9z3gtle2z zNcgoQ@uf>E&=#n%R&nOyw_m9RT4_t9l6kI=szwD6T59E&fxHnDYyUz8X99x9f=GKI zTurCFYU+nn9`BZp;!IYYT?n^*^!`cY{35+-LoU0fw~}+6NqEf;nQ`}WYfFe0=pE8D z0!V3*n(N({KLr)~%qx82pU(H&x$ME8Nu}b4MBY3lTivbU`K52mu&>5>bqcZTE$fij z%uYoBB4jMn>oe`)#5|oARmfTCn4y)n1MUPRCnpGj2rRRd zWANGTBVS1m%B=C|cffx?@Z(|wiU)O$hVksl4Am8kg;|zu9T#cG2 G`MpCJZXAmM From 703b4af5ff015e4df772f24167176b0687723817 Mon Sep 17 00:00:00 2001 From: ian Date: Tue, 22 Jun 2021 10:52:41 +0800 Subject: [PATCH 4/5] ci: remove travis and azure --- .github/workflows/package.yaml | 4 + .travis.yml | 133 ------------------------ azure-pipelines.yml | 75 ------------- devtools/azure/windows-dependencies.yml | 26 ----- 4 files changed, 4 insertions(+), 234 deletions(-) delete mode 100644 .travis.yml delete mode 100644 azure-pipelines.yml delete mode 100644 devtools/azure/windows-dependencies.yml diff --git a/.github/workflows/package.yaml b/.github/workflows/package.yaml index ded4dbdd..69f918c3 100644 --- a/.github/workflows/package.yaml +++ b/.github/workflows/package.yaml @@ -1,5 +1,9 @@ name: Package +concurrency: + group: package-${{ github.ref }} + cancel-in-progress: true + on: push: branches: diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 5710d071..00000000 --- a/.travis.yml +++ /dev/null @@ -1,133 +0,0 @@ -language: rust -rust: 1.46.0 -dist: xenial -sudo: true -cache: - cargo: true - timeout: 1024 - -git: - depth: 2 - submodules: false - -env: - global: - - RUST_BACKTRACE=full - -addons: - apt: - packages: - - libssl-dev - - autoconf - - flex - - bison - - texinfo - - libtool - -before_install: - - cargo sweep --version || travis_retry cargo install --git https://github.com/holmgr/cargo-sweep --rev 4770deda37a2203c783e301b8c0c895964e8971e - - cargo sweep -s - -before_script: - - if [ "$TRAVIS_OS_NAME" = "osx" ]; then ulimit -n 8192; fi - -script: make test - -before_cache: - - rm -rf ./target/release/incremental/ - - rm -rf ./target/debug/incremental/ - - cargo sweep -f - -before_deploy: - - 'export TRAVIS_TAG="${TRAVIS_BRANCH##*/}"' - - git tag $TRAVIS_TAG -deploy: - provider: releases - api_key: "$GITHUB_TOKEN" - file: - - "releases/ckb-cli_${TRAVIS_TAG}_${REL_PKG}" - - "releases/ckb-cli_${TRAVIS_TAG}_${REL_PKG}.asc" - skip_cleanup: true - draft: true - overwrite: true - on: - all_branches: true - condition: '$TRAVIS_BRANCH =~ ^pkg/' - -matrix: - include: - # We don't run tests, linters and quck check in fork branch, since they will be covered in PR. - - name: Tests on macOS - if: 'tag IS NOT present AND (type = pull_request OR branch = master)' - os: osx - - name: Tests on Linux - if: 'tag IS NOT present AND (type = pull_request OR branch = master)' - os: linux - - name: Linters - env: CACHE_NAME=linters - if: 'tag IS NOT present AND (type = pull_request OR branch = master)' - os: linux - install: - - cargo fmt --version || travis_retry rustup component add rustfmt - - cargo clippy --version || travis_retry rustup component add clippy - script: - - make fmt - - make clippy - - git diff --exit-code Cargo.lock - - name: Security Audit - if: 'tag IS NOT present AND (type = pull_request OR branch = master)' - os: linux - rust: nightly - script: make security-audit - - name: PR Integration - if: 'tag IS NOT present AND (type = pull_request OR branch = master)' - os: linux - script: make integration - - - name: Package for macOS - if: 'branch =~ /^pkg\// AND env(GITHUB_TOKEN) IS present' - os: osx - env: REL_PKG=x86_64-apple-darwin.zip - before_install: skip - cache: - directories: - - $HOME/.cargo - before_cache: - - rm -rf $HOME/.cargo/registry - script: - - make OPENSSL_STATIC=1 OPENSSL_LIB_DIR=/usr/local/opt/openssl@1.1/lib OPENSSL_INCLUDE_DIR=/usr/local/opt/openssl@1.1/include prod - - openssl aes-256-cbc -K $encrypted_2e21ee7c4b13_key -iv $encrypted_2e21ee7c4b13_iv -in devtools/ci/travis-secret.asc.enc -out devtools/ci/travis-secret.asc -d - - gpg --import devtools/ci/travis-secret.asc - - devtools/ci/package.sh target/release/ckb-cli - - name: Package for Linux - if: 'branch =~ /^pkg\// AND env(GITHUB_TOKEN) IS present' - language: ruby - addons: { apt: { packages: [] } } - env: REL_PKG=x86_64-unknown-linux-gnu.tar.gz BUILDER_IMAGE=nervos/ckb-docker-builder:xenial-rust-1.46.0 - before_install: skip - before_cache: skip - cache: - directories: - - $HOME/.cargo/git - script: - - mkdir -p $HOME/.cargo/git - - docker run --rm -it -w /ckb-cli -v $(pwd):/ckb-cli -v $HOME/.cargo/git:/root/.cargo/git -e OPENSSL_STATIC=1 -e OPENSSL_LIB_DIR=/usr/local/lib -e OPENSSL_INCLUDE_DIR=/usr/local/include/openssl $BUILDER_IMAGE make prod - - openssl aes-256-cbc -K $encrypted_2e21ee7c4b13_key -iv $encrypted_2e21ee7c4b13_iv -in devtools/ci/travis-secret.asc.enc -out devtools/ci/travis-secret.asc -d - - gpg --import devtools/ci/travis-secret.asc - - devtools/ci/package.sh target/release/ckb-cli - - name: Package for Centos - if: 'branch =~ /^pkg\// AND env(GITHUB_TOKEN) IS present' - language: ruby - addons: { apt: { packages: [] } } - env: REL_PKG=x86_64-unknown-centos-gnu.tar.gz BUILDER_IMAGE=nervos/ckb-docker-builder:centos-7-rust-1.46.0 - before_install: skip - before_cache: skip - cache: - directories: - - $HOME/.cargo/git - script: - - mkdir -p $HOME/.cargo/git - - docker run --rm -it -w /ckb-cli -v $(pwd):/ckb-cli -v $HOME/.cargo/git:/root/.cargo/git $BUILDER_IMAGE scl enable llvm-toolset-7 'make prod' - - openssl aes-256-cbc -K $encrypted_2e21ee7c4b13_key -iv $encrypted_2e21ee7c4b13_iv -in devtools/ci/travis-secret.asc.enc -out devtools/ci/travis-secret.asc -d - - gpg --import devtools/ci/travis-secret.asc - - devtools/ci/package.sh target/release/ckb-cli diff --git a/azure-pipelines.yml b/azure-pipelines.yml deleted file mode 100644 index 4c3ff2aa..00000000 --- a/azure-pipelines.yml +++ /dev/null @@ -1,75 +0,0 @@ -trigger: - branches: - include: - - '*' - tags: - exclude: - - '*' - -jobs: - - job: UnitTest - condition: | - and( - not(startsWith(variables['Build.SourceBranch'], 'refs/tags/')), - or( - eq(variables['Build.Reason'], 'PullRequest'), - eq(variables['Build.SourceBranch'], 'refs/heads/master') - ) - ) - pool: - vmImage: 'VS2017-Win2016' - steps: - - template: devtools/azure/windows-dependencies.yml - parameters: - rustup_toolchain: '1.46.0-x86_64-pc-windows-msvc' - - script: make test - displayName: Run unit tests - env: - CI: true - - - job: Package - timeoutInMinutes: 0 - condition: startsWith(variables['Build.SourceBranch'], 'refs/heads/pkg/') - pool: - vmImage: 'VS2017-Win2016' - steps: - - template: devtools/azure/windows-dependencies.yml - parameters: - rustup_toolchain: '1.46.0-x86_64-pc-windows-msvc' - - script: make prod - displayName: Build - - powershell: | - mkdir ckb-cli_$(Build.SourceBranchName)_x86_64-pc-windows-msvc - cp -r target/release/ckb-cli.exe,README.md,CHANGELOG.md,COPYING ckb-cli_$(Build.SourceBranchName)_x86_64-pc-windows-msvc - displayName: Prepare archive - - task: ArchiveFiles@2 - inputs: - rootFolderOrFile: 'ckb-cli_$(Build.SourceBranchName)_x86_64-pc-windows-msvc' - archiveFile: '$(Build.ArtifactStagingDirectory)/ckb-cli_$(Build.SourceBranchName)_x86_64-pc-windows-msvc.zip' - - script: | - scoop bucket add extras - scoop install gpg4win - displayName: Install GPG4Win - - task: DownloadSecureFile@1 - inputs: - secureFile: azure-secret.asc - - script: | - set PATH=%PATH%;%ProgramFiles(x86)%/GnuPG/bin - gpg --import %DOWNLOADSECUREFILE_SECUREFILEPATH% - echo "##vso[task.setvariable variable=PATH;]%PATH%;%ProgramFiles(x86)%/GnuPG/bin" - displayName: Setup GPG - - script: | - gpg -u "Nervos Azure Builder " -ab "$(Build.ArtifactStagingDirectory)/ckb-cli_$(Build.SourceBranchName)_x86_64-pc-windows-msvc.zip" - displayName: Sign Archive - - task: GitHubRelease@0 - inputs: - gitHubConnection: nervos-bot - repositoryName: nervosnetwork/ckb-cli - action: edit - tag: $(Build.SourceBranchName) - assets: | - $(Build.ArtifactStagingDirectory)/*.zip - $(Build.ArtifactStagingDirectory)/*.asc - assetUploadMode: replace - isDraft: true - addChangeLog: false diff --git a/devtools/azure/windows-dependencies.yml b/devtools/azure/windows-dependencies.yml deleted file mode 100644 index aa2bfa48..00000000 --- a/devtools/azure/windows-dependencies.yml +++ /dev/null @@ -1,26 +0,0 @@ -parameters: - rustup_toolchain: '' -steps: -- powershell: Invoke-Expression (New-Object System.Net.WebClient).DownloadString('https://get.scoop.sh') - displayName: Install scoop -- script: | - set PATH=%PATH%;%USERPROFILE%\scoop\shims - echo "##vso[task.setvariable variable=PATH;]%PATH%;%USERPROFILE%\scoop\shims" - scoop help - displayName: Add scoop to path -- script: scoop install llvm - displayName: Install LLVM -- script: scoop install yasm - displayName: Install yasm -- script: | - curl -sSf -o rustup-init.exe https://win.rustup.rs - rustup-init.exe -y --default-host ${{ parameters.rustup_toolchain }} - set PATH=%PATH%;%USERPROFILE%\.cargo\bin - echo "##vso[task.setvariable variable=PATH;]%PATH%;%USERPROFILE%\.cargo\bin" - displayName: Install rust -- script: | - rustc --version - cargo --version - clang --version - yasm --version - displayName: Test/query binaries From 359528f08b3df13efe2bdbeb35cd092b6e08fcd8 Mon Sep 17 00:00:00 2001 From: ian Date: Tue, 22 Jun 2021 11:58:05 +0800 Subject: [PATCH 5/5] chore: change CI step names --- .github/workflows/package.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/package.yaml b/.github/workflows/package.yaml index 69f918c3..8802e6e8 100644 --- a/.github/workflows/package.yaml +++ b/.github/workflows/package.yaml @@ -45,7 +45,7 @@ jobs: run: | export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` echo "GIT_TAG_NAME=$GIT_TAG_NAME" >> $GITHUB_ENV - - name: Build CKB and Package ckb-cli + - name: Build and package ckb-cli env: LARGE_SECRET_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} GPG_SIGNER: ${{ secrets.GPG_SIGNER }} @@ -81,7 +81,7 @@ jobs: run: | export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` echo "GIT_TAG_NAME=$GIT_TAG_NAME" >> $GITHUB_ENV - - name: Build CKB and Package ckb-cli + - name: Build and package ckb-cli env: LARGE_SECRET_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} GPG_SIGNER: ${{ secrets.GPG_SIGNER }} @@ -117,7 +117,7 @@ jobs: run: | export GIT_TAG_NAME=` echo ${{ github.ref }} | awk -F '/' '{print $4}' ` echo "GIT_TAG_NAME=$GIT_TAG_NAME" >> $GITHUB_ENV - - name: Build CKB and Package ckb-cli + - name: Build and package ckb-cli env: LARGE_SECRET_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} GPG_SIGNER: ${{ secrets.GPG_SIGNER }}