mirror of
https://github.com/fastapi/full-stack-fastapi-template.git
synced 2026-09-22 13:48:42 +00:00
30 lines
802 B
YAML
30 lines
802 B
YAML
name: Test Docker Compose
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
pull_request:
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
|
|
test-docker-compose:
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 10
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
persist-credentials: false
|
|
- run: docker compose build
|
|
- run: docker compose down -v --remove-orphans
|
|
- run: docker compose run --rm backend bash scripts/prestart.sh
|
|
- run: docker compose up -d --wait backend adminer
|
|
- name: Test backend is up
|
|
run: curl http://localhost:8000/api/v1/utils/health-check
|
|
- name: Test frontend is up
|
|
run: curl http://localhost:8000
|
|
- run: docker compose down -v --remove-orphans
|