Test2 #6154
Workflow file for this run
This file contains hidden or 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: Indigo CI | |
env: | |
OS_NAME_MAPPING_JSON: '{"ubuntu-latest": "linux", "windows-latest": "windows", "macos-13": "macos"}' | |
on: | |
push: | |
branches: | |
- master | |
tags: | |
- 'indigo-*' | |
workflow_dispatch: | |
pull_request: | |
repository_dispatch: | |
jobs: | |
build_bingo_postgres_linux_x86_64: | |
strategy: | |
fail-fast: false | |
matrix: | |
postgres_major_version: [ 13 ] | |
runs-on: ubuntu-latest | |
# needs: [build_indigo_windows_mingw_x86_64, build_indigo_ketcher_cjk, build_bingo_oracle_linux_x86_64, build_bingo_oracle_windows_mingw_x86_64, build_bingo_oracle_windows_msvc_x86_64] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
lfs: false | |
fetch-depth: 500 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
- name: Git fetch tags | |
run: | | |
git config --global --add safe.directory '*' | |
git fetch --tags -f | |
- name: Install postgres server headers and build bingo-postgres | |
uses: docker://epmlsop/buildpack-almalinux8:latest | |
with: | |
args: > | |
/bin/sh -c " | |
set -eux && | |
yum install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-8-x86_64/pgdg-redhat-repo-latest.noarch.rpm && | |
curl -OL https://download.postgresql.org/pub/repos/yum/keys/PGDG-RPM-GPG-KEY-RHEL && | |
rpm --import PGDG-RPM-GPG-KEY-RHEL && | |
yumdownloader -y postgresql${{ matrix.postgres_major_version }}-devel && | |
rpm -i --nodeps postgresql${{ matrix.postgres_major_version }}*.rpm && | |
ls -alh /usr && | |
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/rh/httpd24/root/usr/lib64 && | |
mkdir build && | |
cd build && | |
cmake .. -DBUILD_BINGO_POSTGRES=ON -DBUILD_BINGO_SQLSERVER=OFF -DBUILD_BINGO_ORACLE=OFF -DBUILD_INDIGO=OFF -DBUILD_INDIGO_WRAPPERS=OFF -DBUILD_INDIGO_UTILS=OFF -DBUILD_BINGO_ELASTIC=OFF -DCMAKE_PREFIX_PATH=/usr/pgsql-${{ matrix.postgres_major_version }} && | |
cmake --build . --config Release --target package-bingo-postgres -- -j $(nproc) | |
" | |
- name: Upload artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: bingo-postgres-${{ matrix.postgres_major_version }}-linux-x86_64 | |
path: dist/bingo-postgres*.tgz | |
- name: Build Docker image | |
run: | | |
docker build --tag epmlsop/bingo-postgres:${{ matrix.postgres_major_version }}-21 -f bingo/postgres/Dockerfile --build-arg BINGO_PG_VERSION=${{ matrix.postgres_major_version }} . | |
- name: Start Docker container | |
run: | | |
docker run --rm -d -p 5432:5432 -e "POSTGRES_PASSWORD=password" -v /home:/home epmlsop/bingo-postgres:${{ matrix.postgres_major_version }}-21 | |
- name: Install dev dependencies | |
run: | | |
pip install -r bingo/tests/requirements.txt --break-system-packages | |
- name: Run Bingo tests | |
run: | | |
export PYTHONPATH=${{ github.workspace }}/bingo/bingo-elastic/python | |
pytest -s --tb=no --db postgres --junit-xml=junit_report.xml | |
working-directory: bingo/tests | |
- name: Login to DockerHub | |
if: startsWith(github.ref, 'refs/tags/indigo-') | |
uses: docker/login-action@v1 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Publish Docker images | |
if: startsWith(github.ref, 'refs/tags/indigo-') | |
run: docker push epmlsop/bingo-postgres:${{ matrix.postgres_major_version }}-21 | |
- name: Publish Test Report | |
if: always() | |
uses: mikepenz/action-junit-report@v4 | |
with: | |
report_paths: 'bingo/tests/junit_report.xml' | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
check_name: "bingo_postgres_${{ matrix.postgres_major_version }}_test_report" |