--- /dev/null
+name: Build & Test 1.5.x
+
+permissions:
+ contents: read
+
+on:
+ pull_request: {}
+ push:
+ branches:
+ - '!master'
+ paths:
+ - apache-1.5.x/**
+ - fpm-1.5.x/**
+ - fpm-alpin-1.5.x/**
+
+jobs:
+ build-and-testvariants:
+ name: Build image variants and run tests
+ runs-on: ubuntu-latest
+ strategy:
+ fail-fast: false
+ max-parallel: 10
+ matrix:
+ include:
+ - variant: 'apache-1.5.x'
+ test-files: 'apache-postgres'
+ docker-tag: roundcube/roundcubemail:test-apache-1.5.x
+ - variant: 'fpm-1.5.x'
+ test-files: 'fpm-postgres'
+ docker-tag: roundcube/roundcubemail:test-fpm-1.5.x
+ - variant: 'fpm-alpine-1.5.x'
+ test-files: 'fpm-postgres'
+ docker-tag: roundcube/roundcubemail:test-fpm-alpine-1.5.x
+ steps:
+ - name: Checkout repository
+ uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
+ - name: Get docker hub username
+ id: creds
+ run: echo '::set-output name=username::${{ secrets.DOCKER_PULL_USERNAME }}'
+ - name: Login to Docker Hub
+ if: steps.creds.outputs.username != ''
+ uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
+ with:
+ username: ${{ secrets.DOCKER_PULL_USERNAME }}
+ password: ${{ secrets.DOCKER_PULL_PASSWORD }}
+
+ - name: Build image "${{ matrix.variant }}
+ run: cd ${{ matrix.variant }} && docker buildx build ./ -t ${{ matrix.docker-tag }}
+ - name: Run tests
+ run: |
+ set -exu;
+ # Set these here so the values are visible in the logs for debugging.
+ export ROUNDCUBEMAIL_TEST_IMAGE="${{ matrix.docker-tag }}"
+ export HTTP_PORT="${{ matrix.http-port || '80' }}"
+ for testFile in ${{ join(matrix.test-files, ' ') }};
+ do
+ docker compose -f ./tests/docker-compose.test-${testFile}.yml \
+ up --exit-code-from=sut --abort-on-container-exit
+ done