Skip to content

Build workflow

Build workflow #19

Workflow file for this run

name: Build workflow
run-name: Build workflow
on:
workflow_dispatch:
push:
branches:
- master
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-latest
env:
TEST_REDIS: redis://redis:6379
container:
image: debian:bullseye
services:
redis:
image: redis
steps:
-
name: Prepare Environment
run: |
apt-get update && apt-get install -y --no-install-recommends libssl-dev cpanminus make gcc openssl \
zlib1g-dev pkg-config git libpq-dev apt-transport-https ca-certificates \
apt-utils wget curl gnupg2 lsb-release
git config --global --add safe.directory "$GITHUB_WORKSPACE"
-
name: Install Postgres
run: |
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add -
wget --quiet -O - https://dl.2ndquadrant.com/gpg-key.asc | apt-key add -
echo "deb http://apt.postgresql.org/pub/repos/apt/ $(lsb_release -sc)-pgdg main" > /etc/apt/sources.list.d/pgdg.list
echo "deb [arch=$(dpkg --print-architecture)] https://dl.2ndquadrant.com/default/release/apt $(lsb_release -cs)-2ndquadrant main" > /etc/apt/sources.list.d/2ndquadrant.list
echo "deb http://ftp.debian.org/debian $(lsb_release -sc)-backports main" > /etc/apt/sources.list.d/openjdk.list
apt-get -qq update
apt-get install -y pgbouncer postgresql-common postgresql-14 postgresql-client-14 postgresql-contrib-14 pgtap postgresql-14-pgtap postgresql-14-pglogical
-
name: Checkout Code
uses: actions/checkout@v4
-
name: Install Perl Dependencies
run: |
cpanm --quiet --notest Dist::Zilla Dist::Zilla::App::Command::cover Devel::Cover::Report::Codecov
cpanm --quiet --notest $(dzil authordeps --missing)
cpanm -n --installdeps .
cpanm --quiet --notest $(dzil listdeps --author --missing)
-
name: Run Smoke Test
run: dzil smoke --release --author
-
name: Run Coverage Test
run: dzil cover -test -report codecov
-
name: Run extended author test
run: dzil xtest