Test_centos7_release_126 #175
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-cpp-centos7 | |
on: | |
workflow_dispatch: {} | |
pull_request: | |
types: [opened, synchronize, ready_for_review] | |
push: | |
release: | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
linux: | |
name: Linux | |
runs-on: ubuntu-latest | |
container: 'centos:centos7' | |
steps: | |
- name: Install Dependancies | |
run: | | |
yum update -y | |
yum install -y epel-release | |
yum install -y git redhat-lsb-core make wget centos-release-scl scl-utils | |
yum install -y devtoolset-9 | |
- name: Setup cmake | |
uses: jwlawson/[email protected] | |
with: | |
cmake-version: '3.22.x' | |
- name: Checkout sources | |
uses: actions/checkout@v1 | |
- name: Download Boost-release | |
uses: dsaltares/fetch-gh-release-asset@master | |
with: | |
repo: 'ARnDOSrte/Boost' | |
file: 'boost_1_73_0.zip' | |
target: 'boost_1_73_0.zip' | |
token: ${{ secrets.TEST_TOKEN_RELEASE }} | |
- name: Unzip Boost | |
run: unzip boost_1_73_0.zip | |
- name: Configure 3rd parties | |
run: | | |
source /opt/rh/devtoolset-9/enable | |
cmake -S $GITHUB_WORKSPACE/metrix-simulator/external -B $GITHUB_WORKSPACE/metrix-simulator/build-centos7/external | |
- name: Build 3rd parties | |
run: | | |
cmake --build $GITHUB_WORKSPACE/metrix-simulator/build-centos7/external --parallel 2 | |
- name: Configure CMake | |
run: | | |
source /opt/rh/devtoolset-9/enable | |
cmake -S $GITHUB_WORKSPACE/metrix-simulator -Wno-dev -DCMAKE_BUILD_TYPE=Release -DBoost_ROOT=$GITHUB_WORKSPACE/__w/Boost/Boost/boost_1_73_0/installBoost -DBoost_INCLUDE_DIR=$GITHUB_WORKSPACE/__w/Boost/Boost/boost_1_73_0/installBoost -DCMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/metrix-simulator/build-centos7/install -B $GITHUB_WORKSPACE/metrix-simulator/build-centos7 | |
- name: Build | |
run: cmake --build $GITHUB_WORKSPACE/metrix-simulator/build-centos7 --target install --parallel 2 | |
- name: Tests | |
run: cd $GITHUB_WORKSPACE/metrix-simulator/build-centos7 && ctest -j2 --output-on-failure | |
- name: Prepare Metrix install | |
if: github.event_name == 'workflow_dispatch' | |
id: metrix-install | |
run: | | |
ARCHIVE_NAME="metrix-simulator-centos7.zip" | |
ARCHIVE_PATH="$PWD/${ARCHIVE_NAME}" | |
cd metrix-simulator/build-centos7/install/ | |
zip -r $ARCHIVE_PATH bin etc | |
echo "::set-output name=archive_name::$ARCHIVE_NAME" | |
echo "::set-output name=archive_path::$ARCHIVE_PATH" | |
- name: Upload OR-Tools install artifact | |
if: github.event_name == 'workflow_dispatch' | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ steps.metrix-install.outputs.archive_name }} | |
path: ${{ steps.metrix-install.outputs.archive_path }} |