mirror of
https://github.com/openstreetmap/mod_tile.git
synced 2025-07-25 01:20:03 +00:00

* Improve service startup "tests" * Address intermittent download test failure * Caused by load exceeding threshold * Add more missing bad HTTPD config tests * Allow for newer `libpng` with Docker tests * Also test more image/file types
77 lines
2.5 KiB
YAML
77 lines
2.5 KiB
YAML
---
|
|
name: Docker Image Build
|
|
|
|
on:
|
|
pull_request:
|
|
push:
|
|
paths:
|
|
- "docker/**"
|
|
- ".github/workflows/docker-image-build.yml"
|
|
|
|
jobs:
|
|
docker-image-build:
|
|
name: Build & Test (${{ matrix.service-name }})
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
service-name:
|
|
- archlinux
|
|
- centos-7
|
|
- centos-stream-8
|
|
- centos-stream-9
|
|
- debian-11
|
|
- debian-12
|
|
- debian-testing
|
|
- debian-testing-autotools
|
|
- fedora-38
|
|
- fedora-39
|
|
- fedora-rawhide
|
|
- opensuse-leap-15
|
|
- opensuse-tumbleweed
|
|
- ubuntu-20.04
|
|
- ubuntu-22.04
|
|
- ubuntu-devel
|
|
- ubuntu-devel-autotools
|
|
fail-fast: false
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Build & Start
|
|
run: docker compose up --build --detach ${{ matrix.service-name }}
|
|
working-directory: docker
|
|
|
|
- name: Test
|
|
run: |
|
|
until $(curl --fail --output tile.jpg.file.0 --silent http://localhost:8081/tiles/renderd-example-jpg/9/297/191.jpg); do
|
|
echo 'Sleeping 5s';
|
|
sleep 5;
|
|
done
|
|
sha256sum --check --ignore-missing tests/tiles.sha256sum | grep tile.jpg.file.0 | grep -q OK
|
|
until $(curl --fail --output tile.png256.file.0 --silent http://localhost:8081/tiles/renderd-example-png256/9/297/191.png); do
|
|
echo 'Sleeping 5s';
|
|
sleep 5;
|
|
done
|
|
sha256sum --check --ignore-missing tests/tiles.sha256sum | grep tile.png256.file.0 | grep -q OK
|
|
until $(curl --fail --output tile.png32.file.0 --silent http://localhost:8081/tiles/renderd-example-png32/9/297/191.png); do
|
|
echo 'Sleeping 5s';
|
|
sleep 5;
|
|
done
|
|
sha256sum --check --ignore-missing tests/tiles.sha256sum | grep tile.png32.file.0 | grep -q OK
|
|
until $(curl --fail --output tile.webp.file.0 --silent http://localhost:8081/tiles/renderd-example-webp/9/297/191.webp); do
|
|
echo 'Sleeping 5s';
|
|
sleep 5;
|
|
done
|
|
sha256sum --check --ignore-missing tests/tiles.sha256sum | grep tile.webp.file.0 | grep -q OK
|
|
timeout-minutes: 1
|
|
|
|
- name: Show logs
|
|
if: failure()
|
|
run: docker compose logs
|
|
working-directory: docker
|
|
|
|
- name: Stop
|
|
if: success() || failure()
|
|
run: docker compose down --volumes
|
|
working-directory: docker
|