Skip to content

(lint) fixing lint errors #83

(lint) fixing lint errors

(lint) fixing lint errors #83

Workflow file for this run

name: Build for Centos
# manually triggered workflow
# or when this file changes
on:
workflow_dispatch:
push:
paths:
- '.github/workflows/centos.yml'
- 'src/**'
- 'include/**'
- 'pgtap/**'
- 'tools/testers/**'
- './CMakeLists.txt'
branches-ignore:
- 'gh-pages'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build:
name: centos-7-gcc-4.8.5
runs-on:
- self-hosted
- centos-7 gcc-4.8.5
steps:
- uses: actions/checkout@v3
- name: get postgres version
run: |
echo "PGVER=15" >> $GITHUB_ENV
echo "PGPORT=5432" >> $GITHUB_ENV
- name: Configure for gcc
run: |
mkdir build
cd build
export PATH=${PATH}:/usr/pgsql-${PGVER}/bin
cmake3 -DCMAKE_BUILD_TYPE=Release -DBOOST_ROOT:PATH="/opt/boost" ..
- name: Build
run: |
cd build
make -j 4
- name: Install
run: |
cd build
sudo make install
- name: Test
run: |
sudo systemctl restart postgresql-15
export PGPORT=5432
export PG_RUNNER_USER=`whoami`
sudo -u postgres psql -p ${PGPORT} -c "DROP DATABASE IF EXISTS ___pgr___test___;"
sudo -u postgres psql -p ${PGPORT} -c "DROP DATABASE IF EXISTS \"${PG_RUNNER_USER}\";"
sudo -u postgres psql -p ${PGPORT} -c "DROP ROLE IF EXISTS \"${PG_RUNNER_USER}\";"
sudo -u postgres psql -p ${PGPORT} -c "CREATE ROLE \"${PG_RUNNER_USER}\" WITH LOGIN SUPERUSER;"
sudo -u postgres psql -p ${PGPORT} -c "CREATE DATABASE \"${PG_RUNNER_USER}\";"
psql -c "CREATE DATABASE ___pgr___test___;"
./tools/testers/pg_prove_tests.sh ${PG_RUNNER_USER} ${PGPORT} Release
psql -c "DROP DATABASE IF EXISTS ___pgr___test___;"