initial commit
Build and Push Docker Images / build-and-push (push) Failing after 3m33s

This commit is contained in:
admin committed 2026-11-07 16:39:43 +03:00
commit 46af290db3
100 files changed
+16663

No files matched your search

+64
View File
@@ -0,0 +1,64 @@
version: '3.8'
services:
# Backend (FastAPI)
backend:
build:
context: ./backend
dockerfile: Dockerfile
container_name: writer-ide-backend
restart: unless-stopped
ports:
- "8000:8000"
env_file:
- .env
environment:
- DATA_DIR=/app/data
- OLLAMA_BASE_URL=${OLLAMA_BASE_URL:-http://host.docker.internal:11434}
- ENVIRONMENT=production
volumes:
# Монтируем HDD с данными в контейнер
- ${DATA_VOLUME_PATH:-/mnt/data/writer-ide}:/app/data
# Монтируем .env файл (опционально, если нужен hot-reload)
- ./backend/.env:/app/.env:ro
extra_hosts:
# Для доступа к Ollama на хосте (Linux)
- "host.docker.internal:host-gateway"
networks:
- writer-ide-network
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/api/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
# Frontend (Next.js)
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
container_name: writer-ide-frontend
restart: unless-stopped
ports:
- "3000:3000"
environment:
- NEXT_PUBLIC_API_URL=${NEXT_PUBLIC_API_URL:-http://localhost:8000/api}
- NODE_ENV=production
depends_on:
backend:
condition: service_healthy
networks:
- writer-ide-network
healthcheck:
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:3000"]
interval: 30s
timeout: 10s
retries: 3
start_period: 60s
networks:
writer-ide-network:
driver: bridge
# Volumes не определяем явно, так как используем bind mount с HDD