116 lines
3.2 KiB
YAML
116 lines
3.2 KiB
YAML
services:
|
|
frontend:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/frontend/Dockerfile
|
|
environment:
|
|
NEXT_TELEMETRY_DISABLED: "1"
|
|
BACKEND_URL: http://backend:8000
|
|
ports:
|
|
- "${FRONTEND_PORT:-3000}:3000"
|
|
depends_on:
|
|
backend:
|
|
condition: service_started
|
|
|
|
backend:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/backend/Dockerfile
|
|
environment:
|
|
PIPELINE_DEMO_MODE: "1"
|
|
PIPELINE_DEMO_PUBLISH_REPO_PATH: /demo/pipeline-demo-site.git
|
|
POSTGRES_DSN: postgresql://${POSTGRES_USER:-pipeline}:${POSTGRES_PASSWORD:-pipeline_local}@postgres:5432/${POSTGRES_DB:-pipeline}
|
|
REDIS_URL: redis://redis:6379/0
|
|
OBJECT_STORAGE_ENDPOINT: http://minio:9000
|
|
OBJECT_STORAGE_ACCESS_KEY_ID: ${MINIO_ROOT_USER:-minio_local}
|
|
OBJECT_STORAGE_SECRET_ACCESS_KEY: ${MINIO_ROOT_PASSWORD:-minio_local_password}
|
|
OBJECT_STORAGE_BUCKET: ${OBJECT_STORAGE_BUCKET:-pipeline-local}
|
|
OBJECT_STORAGE_REGION: ${OBJECT_STORAGE_REGION:-us-east-1}
|
|
volumes:
|
|
- demo-publish-repo:/demo
|
|
ports:
|
|
- "${BACKEND_PORT:-8000}:8000"
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
redis:
|
|
condition: service_healthy
|
|
minio-init:
|
|
condition: service_completed_successfully
|
|
|
|
runner:
|
|
build:
|
|
context: .
|
|
dockerfile: apps/runner/Dockerfile
|
|
environment:
|
|
RUNNER_MODE: fake
|
|
BACKEND_URL: http://backend:8000
|
|
ports:
|
|
- "${RUNNER_PORT:-8010}:8010"
|
|
depends_on:
|
|
backend:
|
|
condition: service_started
|
|
|
|
postgres:
|
|
image: postgres:16-alpine
|
|
environment:
|
|
POSTGRES_USER: ${POSTGRES_USER:-pipeline}
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-pipeline_local}
|
|
POSTGRES_DB: ${POSTGRES_DB:-pipeline}
|
|
ports:
|
|
- "${POSTGRES_PORT:-5432}:5432"
|
|
volumes:
|
|
- postgres-data:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}"]
|
|
interval: 5s
|
|
timeout: 3s
|
|
retries: 20
|
|
|
|
redis:
|
|
image: redis:7-alpine
|
|
ports:
|
|
- "${REDIS_PORT:-6379}:6379"
|
|
volumes:
|
|
- redis-data:/data
|
|
healthcheck:
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
interval: 5s
|
|
timeout: 3s
|
|
retries: 20
|
|
|
|
minio:
|
|
image: minio/minio:latest
|
|
command: server /data --console-address ":9001"
|
|
environment:
|
|
MINIO_ROOT_USER: ${MINIO_ROOT_USER:-minio_local}
|
|
MINIO_ROOT_PASSWORD: ${MINIO_ROOT_PASSWORD:-minio_local_password}
|
|
ports:
|
|
- "${MINIO_API_PORT:-9000}:9000"
|
|
- "${MINIO_CONSOLE_PORT:-9001}:9001"
|
|
volumes:
|
|
- minio-data:/data
|
|
|
|
minio-init:
|
|
image: minio/mc:latest
|
|
depends_on:
|
|
minio:
|
|
condition: service_started
|
|
environment:
|
|
MINIO_ROOT_USER: ${MINIO_ROOT_USER:-minio_local}
|
|
MINIO_ROOT_PASSWORD: ${MINIO_ROOT_PASSWORD:-minio_local_password}
|
|
OBJECT_STORAGE_BUCKET: ${OBJECT_STORAGE_BUCKET:-pipeline-local}
|
|
entrypoint: ["/bin/sh", "-c"]
|
|
command:
|
|
- >
|
|
until mc alias set local http://minio:9000 "$$MINIO_ROOT_USER" "$$MINIO_ROOT_PASSWORD"; do
|
|
sleep 1;
|
|
done;
|
|
mc mb --ignore-existing "local/$$OBJECT_STORAGE_BUCKET";
|
|
|
|
volumes:
|
|
postgres-data:
|
|
redis-data:
|
|
minio-data:
|
|
demo-publish-repo:
|