50 lines
1.5 KiB
YAML
50 lines
1.5 KiB
YAML
services:
|
|
postgres:
|
|
image: tensorzero/postgres:14
|
|
environment:
|
|
POSTGRES_DB: tensorzero_ui_fixtures
|
|
POSTGRES_USER: postgres
|
|
POSTGRES_PASSWORD: postgres
|
|
command: [ "postgres", "-c", "cron.database_name=tensorzero_ui_fixtures" ]
|
|
ports:
|
|
- "5432:5432"
|
|
healthcheck:
|
|
test: [ "CMD-SHELL", "pg_isready -U postgres -d tensorzero_ui_fixtures" ]
|
|
start_period: 30s
|
|
start_interval: 1s
|
|
timeout: 1s
|
|
|
|
gateway-postgres-migrations:
|
|
image: tensorzero/gateway:${TENSORZERO_GATEWAY_TAG:-latest}
|
|
build:
|
|
context: ../../
|
|
dockerfile: crates/gateway/Dockerfile
|
|
target: gateway
|
|
args:
|
|
PROFILE: dev
|
|
environment:
|
|
TENSORZERO_POSTGRES_URL: postgres://postgres:postgres@postgres:5432/tensorzero_ui_fixtures
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
entrypoint: [ "/bin/sh", "-c" ]
|
|
command: [ "gateway --run-postgres-migrations && touch /tmp/migrations_complete.marker && sleep infinity" ]
|
|
extra_hosts:
|
|
- "howdy.tensorzero.com:127.0.0.1"
|
|
healthcheck:
|
|
test: [ "CMD", "test", "-f", "/tmp/migrations_complete.marker" ]
|
|
interval: 5s
|
|
timeout: 1s
|
|
retries: 72 # Retry for up to 6 minutes
|
|
start_period: 5s
|
|
|
|
mock-provider-api:
|
|
image: tensorzero/mock-provider-api:${TENSORZERO_MOCK_PROVIDER_API_TAG:-${TENSORZERO_COMMIT_TAG:-latest}}
|
|
build:
|
|
context: ../../
|
|
dockerfile: crates/tensorzero-core/tests/mock-provider-api/Dockerfile
|
|
environment:
|
|
RUST_LOG: debug
|
|
ports:
|
|
- "3030:3030"
|