Initial commit: Complete NodeJS-native setup
- Migrated from Python pre-commit to NodeJS-native solution - Reorganized documentation structure - Set up Husky + lint-staged for efficient pre-commit hooks - Fixed Dockerfile healthcheck issue - Added comprehensive documentation index
This commit is contained in:
65
docker/docker-compose.yaml
Normal file
65
docker/docker-compose.yaml
Normal file
@@ -0,0 +1,65 @@
|
||||
services:
|
||||
# Frontend service
|
||||
frontend:
|
||||
build:
|
||||
context: .
|
||||
args:
|
||||
# CouchDB Configuration
|
||||
- VITE_COUCHDB_URL=${VITE_COUCHDB_URL:-http://couchdb:5984}
|
||||
- VITE_COUCHDB_USER=${VITE_COUCHDB_USER:-admin}
|
||||
- VITE_COUCHDB_PASSWORD=${VITE_COUCHDB_PASSWORD:-change-this-secure-password}
|
||||
# Application Configuration
|
||||
- APP_BASE_URL=${APP_BASE_URL:-http://localhost:8080}
|
||||
# OAuth Configuration (Optional)
|
||||
- VITE_GOOGLE_CLIENT_ID=${VITE_GOOGLE_CLIENT_ID:-}
|
||||
- VITE_GITHUB_CLIENT_ID=${VITE_GITHUB_CLIENT_ID:-}
|
||||
# Build Environment
|
||||
- NODE_ENV=${NODE_ENV:-production}
|
||||
# Enable buildx for multi-platform builds
|
||||
platforms:
|
||||
- linux/amd64
|
||||
- linux/arm64
|
||||
ports:
|
||||
- '8080:80'
|
||||
depends_on:
|
||||
couchdb:
|
||||
condition: service_healthy
|
||||
restart: unless-stopped
|
||||
# Health check for the frontend container
|
||||
healthcheck:
|
||||
test: ['CMD', 'curl', '-f', 'http://localhost/']
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 40s
|
||||
labels:
|
||||
- 'monitoring=true'
|
||||
- 'service=frontend'
|
||||
|
||||
# CouchDB service
|
||||
couchdb:
|
||||
image: couchdb:3.3.2
|
||||
volumes:
|
||||
- ./couchdb-data:/opt/couchdb/data
|
||||
environment:
|
||||
- COUCHDB_USER=${COUCHDB_USER:-admin}
|
||||
- COUCHDB_PASSWORD=${COUCHDB_PASSWORD:-change-this-secure-password}
|
||||
ports:
|
||||
- '5984:5984'
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ['CMD', 'curl', '-f', 'http://localhost:5984/_up']
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
labels:
|
||||
- 'monitoring=true'
|
||||
- 'service=couchdb'
|
||||
|
||||
# Redis service (commented out as per requirements)
|
||||
# redis:
|
||||
# image: redis:alpine
|
||||
# restart: unless-stopped
|
||||
# labels:
|
||||
# - "monitoring=true"
|
||||
# - "service=redis"
|
||||
Reference in New Issue
Block a user