Skip to content

Test patch on v0.12.x #7760

Test patch on v0.12.x

Test patch on v0.12.x #7760

name: Release build (clang)
on: [push, pull_request]
jobs:
build:
name: Build
runs-on: ubuntu-18.04
strategy:
fail-fast: false
matrix:
compiler:
- "CONCORD_BFT_CONTAINER_CC=clang CONCORD_BFT_CONTAINER_CXX=clang++"
ci_build_type:
- "-DCMAKE_BUILD_TYPE=RELEASE -DBUILD_COMM_TCP_TLS=FALSE"
- "-DCMAKE_BUILD_TYPE=RELEASE -DBUILD_COMM_TCP_TLS=TRUE"
use_s3_obj_store:
- "-DUSE_S3_OBJECT_STORE=ON"
- "-DUSE_S3_OBJECT_STORE=OFF"
steps:
- name: Cleanup pre-installed tools
run: |
# This is a fix for https://github.com/actions/virtual-environments/issues/1918
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf "/usr/local/share/boost"
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
- name: Checkout
uses: actions/checkout@v2
- name: Create artifact directory
run: mkdir -p ${{ github.workspace }}/artifact
#- name: Configure core dump location
# run: |
# Uncomment the line below to enable core dump collection
# echo "/concord-bft/build/cores/core.%e.%p" | sudo tee /proc/sys/kernel/core_pattern
# Uncomment this is you want to login into the running session.
# Please note that the build will block on this step.
# Refer to https://github.com/marketplace/actions/debugging-with-tmate
#- name: Setup tmate session
# uses: mxschmitt/action-tmate@v2
- name: Build and test
run: |
script -q -e -c "make pull"
sudo df -h
script -q -e -c "make build \
${{ matrix.compiler}} \
CONCORD_BFT_CMAKE_FLAGS=\"\
${{ matrix.ci_build_type }} \
-DBUILD_TESTING=ON \
-DBUILD_COMM_TCP_PLAIN=FALSE \
-DCMAKE_CXX_FLAGS_RELEASE='-O3 -g' \
-DUSE_LOG4CPP=TRUE \
-DBUILD_ROCKSDB_STORAGE=TRUE \
${{ matrix.use_s3_obj_store }} \
-DUSE_OPENTRACING=ON \
-DOMIT_TEST_OUTPUT=OFF\
-DKEEP_APOLLO_LOGS=TRUE\
-DUSE_FAKE_CLOCK_IN_TIME_SERVICE=TRUE\" "\
&& script -q -e -c "make test"
- name: Prepare artifacts
if: failure()
run: |
sudo chown -R ${USER}:${GROUP} ${PWD}/build
tar -czvf ${{ github.workspace }}/artifact/logs.tar.gz ./build/tests/apollo/logs
du -h ${{ github.workspace }}/artifact
sudo df -h
- name: Upload artifacts
uses: actions/upload-artifact@v2
if: failure()
with:
name: artifacts-${{ matrix.compiler }}-${{ matrix.ci_build_type }}-${{ github.sha }}
path: ${{ github.workspace }}/artifact/