diff --git a/.github/workflows/centos7.yml b/.github/workflows/centos7.yml index 853abb1463..aa3b3b46f2 100644 --- a/.github/workflows/centos7.yml +++ b/.github/workflows/centos7.yml @@ -38,20 +38,24 @@ jobs: uses: actions/checkout@v2 with: submodules: true - + - name: Set up Python + id: python-path + run: | + source /opt/rh/rh-python36/enable + python -c "import sys; print(sys.version)" + run: echo "::set-output name=PYTHON_EXECUTABLE::$(python -c 'import sys; import pathlib; print (pathlib.PurePath(sys.executable).as_posix())')" - name: Build ResInsight - run: | - + run: | source /opt/rh/devtoolset-7/enable source /opt/rh/rh-python36/enable - + cmake3 --version git --version g++ --version - python --version + ${{ steps.python-path.outputs.PYTHON_EXECUTABLE }} --version - python -m pip install --upgrade pip - python -m pip install grpcio-tools + ${{ steps.python-path.outputs.PYTHON_EXECUTABLE }} -m pip install --upgrade pip + ${{ steps.python-path.outputs.PYTHON_EXECUTABLE }} -m pip install grpcio-tools ThirdParty/vcpkg/bootstrap-vcpkg.sh ThirdParty/vcpkg/vcpkg install grpc boost-filesystem eigen3 @@ -64,7 +68,7 @@ jobs: -DRESINSIGHT_ENABLE_UNITY_BUILD=true \ -DVCPKG_TARGET_TRIPLET=x64-linux \ -DCMAKE_TOOLCHAIN_FILE=../ThirdParty/vcpkg/scripts/buildsystems/vcpkg.cmake \ - -DRESINSIGHT_GRPC_PYTHON_EXECUTABLE=python \ + -DRESINSIGHT_GRPC_PYTHON_EXECUTABLE=${{ steps.python-path.outputs.PYTHON_EXECUTABLE }} \ -DRESINSIGHT_GRPC_DOWNLOAD_PYTHON_MODULE=true \ ..