fix conflict by loop bug #637
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
name: Centos CI Check | |
on: | |
push: | |
paths-ignore: | |
- "docs/**" | |
- "Changelog.md" | |
- "README.md" | |
pull_request: | |
paths-ignore: | |
- "docs/**" | |
- "Changelog.md" | |
- "README.md" | |
release: | |
types: [push] | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build_centos: | |
name: centos ci check | |
runs-on: self-hosted-centos | |
strategy: | |
fail-fast: false | |
env: | |
VCPKG_ROOT: ~/cache/vcpkg | |
DEPS_ROOT: ~/cache/deps | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
clean: false | |
- name: Set up JDK 1.8 | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'zulu' | |
java-version: 8 | |
java-package: jdk | |
- name: Set up Node.js 16.x | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '16.x' | |
- name: yum install | |
run: | | |
sudo yum install -y -q epel-release centos-release-scl flex bison patch gmp-static glibc-static glibc-devel libzstd-devel | |
sudo yum install -y -q devtoolset-11 llvm-toolset-7.0 rh-perl530-perl cmake3 zlib-devel ccache python-devel python3-devel python3-pip automake openssl | |
sudo yum reinstall -y -q https://packages.endpointdev.com/rhel/7/os/x86_64/endpoint-repo.x86_64.rpm | |
sudo yum install -y -q git | |
- uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly-2022-07-28 | |
override: true | |
- name: Reuse build cache | |
run: | | |
mkdir -p ./build | |
rm -rf deps | |
ln -s ${{ env.DEPS_ROOT }} deps | |
- name: Remove cache if correspond dir change | |
run: ./tools/.ci/clear_build_cache.sh | |
- name: Config vcpkg registry proxy | |
run: sed -i "s/https:\/\/github.com/http:\/\/ghproxy.com\/https:\/\/github.com/g" vcpkg-configuration.json | |
- name: update vcpkg | |
run: | | |
cd ${{ env.VCPKG_ROOT }} && git checkout master #&& git pull | |
cd - | |
- name: Build for linux | |
run: | | |
. /opt/rh/devtoolset-11/enable | |
. /opt/rh/rh-perl530/enable | |
export LIBCLANG_PATH=/opt/rh/llvm-toolset-7.0/root/lib64/ | |
. /opt/rh/llvm-toolset-7.0/enable | |
alias cmake='cmake3' | |
cd build && cmake3 -DALLOCATOR=jemalloc -DCMAKE_TOOLCHAIN_FILE=${{ env.VCPKG_ROOT }}/scripts/buildsystems/vcpkg.cmake -DTESTS=ON -DCOVERAGE=ON -DWITH_LIGHTNODE=ON -DWITH_CPPSDK=ON -DWITH_TIKV=OFF -DWITH_TARS_SERVICES=ON -DURL_BASE=ghproxy.com/github.com .. || cat *.log | |
make -j8 | |
- name: Test | |
run: | |
cd build && CTEST_OUTPUT_ON_FAILURE=TRUE make test && make coverage && curl -LO https://codecov.io/bash && /bin/bash ./bash && bash ../tools/.ci/check_coverage.sh | |
# - name: Add comment | |
# env: | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
# run: | | |
# PR_NUMBER=$(echo $GITHUB_REF | awk 'BEGIN { FS = "/" } ; { print $3 }') && | |
# cd build && curl -L -X POST \ | |
# -H "Accept: application/vnd.github+json" \ | |
# -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ | |
# -H "X-GitHub-Api-Version: 2022-11-28" \ | |
# "https://api.github.com/repos/FISCO-BCOS/FISCO-BCOS/pulls/${PR_NUMBER}/comments" \ | |
# --data '{"body":"$(bash ../tools/.ci/check_coverage.sh)"}' | |
# - name: upload coverage report | |
# uses: codecov/codecov-action@v2 | |
# with: | |
# files: ./build/coverage.info | |
# version: "v0.1.15" | |
# flags: unittests | |
# name: FISCO BCOS coverage | |
# fail_ci_if_error: false | |
# verbose: true | |
- name: prepare RPCAPI Tests | |
run: cd tools && bash .ci/rpcapi_ci_prepare.sh | |
- name: FISCO BCOS RpcApiTest | |
uses: matt-ball/newman-action@master | |
with: | |
collection: https://raw.githubusercontent.com/FISCO-BCOS/FISCOBCOS-RPC-API/main/fiscobcos.rpcapi.collection.json | |
- name: Integration test - Air | |
run: cd tools && bash .ci/ci_check_air.sh ${{ github.base_ref }} |