Merge pull request #3955 from marta-lokhova/upgrade_herder_test #3987
Workflow file for this run
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: CI | |
on: | |
pull_request: | |
push: | |
branches: | |
- auto | |
jobs: | |
rust-check-git-rev-deps: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: stellar/actions/rust-check-git-rev-deps@main | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
toolchain: [ "gcc", "clang"] | |
protocol: ["current"] | |
scenario: ["", "--check-test-tx-meta"] | |
steps: | |
- name: Compute cache key | |
# this step works around a limitation in actions/cache | |
# that does not allow updating a cache | |
# so what we do here instead is | |
# 1. generate a new id that gets refreshed every hour | |
# the limit is to reduce the chance of hitting the | |
# global 5GB limit per repo | |
# 2. use that id as part of the cache identifier | |
# 3. fallback (restore-keys) to the most recent cache | |
id: cache_extra_id | |
run: | | |
echo "id=$(( $(date +'%s') / 60 / 60 ))" >> $GITHUB_OUTPUT | |
- name: Cache | |
uses: actions/[email protected] | |
with: | |
path: | | |
/home/runner/.ccache | |
key: ${{ runner.os }}-${{ matrix.toolchain }}-${{ matrix.protocol }}-cacheID-${{ steps.cache_extra_id.outputs.id }} | |
restore-keys: | | |
${{ runner.os }}-${{ matrix.toolchain }}-${{ matrix.protocol }}-cacheID- | |
- uses: actions/[email protected] | |
with: | |
fetch-depth: 200 | |
submodules: true | |
- name: install core packages | |
run: | | |
sudo apt-get update | |
sudo apt-get -y install --no-install-recommends apt-utils dialog git iproute2 procps lsb-release | |
- name: install tool chain | |
run: | | |
sudo apt-get -y install libstdc++-10-dev clang-format-12 ccache lldb | |
if test "${{ matrix.toolchain }}" = "gcc" ; then | |
sudo apt-get -y install cpp-10 gcc-10 g++-10 | |
else | |
sudo apt-get -y install clang-12 llvm-12 | |
fi | |
- name: install dependencies | |
run: sudo apt-get -y install postgresql git build-essential pkg-config autoconf automake libtool bison flex libpq-dev parallel libunwind-dev sed perl | |
- name: Build | |
run: | | |
if test "${{ matrix.toolchain }}" = "gcc" ; then | |
export CC='gcc' | |
export CXX='g++' | |
else | |
export CC='clang' | |
export CXX='clang++' | |
fi | |
echo Build with $CC and $CXX | |
./ci-build.sh --use-temp-db --protocol ${{ matrix.protocol }} ${{ matrix.scenario }} |