Some checks failed
Build / Build Backend (push) Has been cancelled
Build / Build Mobile (TypeScript Check) (push) Has been cancelled
Lint / Lint Backend (push) Has been cancelled
Lint / Lint Mobile (push) Has been cancelled
Test / Backend E2E Tests (push) Has been cancelled
Test / Mobile Unit Tests (push) Has been cancelled
Build / Build Docker Image (push) Has been cancelled
- backend/ → apps/backend/, database/ → apps/database/, mobile/ → apps/frontend-mobile/ - Updated .gitmodules, docker-compose.yml, CLAUDE.md v1.0.0 - Added apps/_MAP.md Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
86 lines
2.1 KiB
YAML
86 lines
2.1 KiB
YAML
version: '3.8'
|
|
|
|
services:
|
|
# PostgreSQL Database
|
|
postgres:
|
|
image: postgres:15-alpine
|
|
container_name: miinventario-postgres
|
|
restart: unless-stopped
|
|
environment:
|
|
POSTGRES_USER: postgres
|
|
POSTGRES_PASSWORD: postgres
|
|
POSTGRES_DB: miinventario_dev
|
|
ports:
|
|
- "5433:5432"
|
|
volumes:
|
|
- miinventario_postgres_data:/var/lib/postgresql/data
|
|
- ./apps/database/schemas:/docker-entrypoint-initdb.d:ro
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U postgres"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 5
|
|
|
|
# Redis (Cache y Cola de trabajos)
|
|
redis:
|
|
image: redis:7-alpine
|
|
container_name: miinventario-redis
|
|
restart: unless-stopped
|
|
ports:
|
|
- "6380:6379"
|
|
volumes:
|
|
- miinventario_redis_data:/data
|
|
command: redis-server --appendonly yes
|
|
healthcheck:
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 5
|
|
|
|
# MinIO (S3 Compatible Storage)
|
|
minio:
|
|
image: minio/minio:latest
|
|
container_name: miinventario-minio
|
|
restart: unless-stopped
|
|
command: server /data --console-address ":9001"
|
|
environment:
|
|
MINIO_ROOT_USER: minioadmin
|
|
MINIO_ROOT_PASSWORD: minioadmin
|
|
ports:
|
|
- "9002:9000" # API
|
|
- "9003:9001" # Console
|
|
volumes:
|
|
- miinventario_minio_data:/data
|
|
healthcheck:
|
|
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
|
|
interval: 30s
|
|
timeout: 20s
|
|
retries: 3
|
|
|
|
# MinIO Setup (crear bucket inicial)
|
|
minio-setup:
|
|
image: minio/mc:latest
|
|
container_name: miinventario-minio-setup
|
|
depends_on:
|
|
minio:
|
|
condition: service_healthy
|
|
entrypoint: >
|
|
/bin/sh -c "
|
|
mc alias set myminio http://minio:9000 minioadmin minioadmin;
|
|
mc mb myminio/miinventario --ignore-existing;
|
|
mc anonymous set download myminio/miinventario;
|
|
exit 0;
|
|
"
|
|
|
|
volumes:
|
|
miinventario_postgres_data:
|
|
name: miinventario_postgres_data
|
|
miinventario_redis_data:
|
|
name: miinventario_redis_data
|
|
miinventario_minio_data:
|
|
name: miinventario_minio_data
|
|
|
|
networks:
|
|
default:
|
|
name: miinventario_network
|