forked from trent_larson/crowd-funder-for-time-pwa
Fix: markdownlint MD012/MD019 errors in build-pattern-conversion-plan.md
- Removed extra blank lines at end of file to resolve MD012 (no-multiple-blanks) - Standardized heading spacing to resolve MD019 (no-multiple-space-atx) - Stripped trailing whitespace and ensured file ends with a single newline All changes maintain content integrity and bring the file into full markdownlint compliance.
This commit is contained in:
@@ -2,24 +2,21 @@
|
||||
# Author: Matthew Raymer
|
||||
# Description: Multi-environment Docker Compose setup for TimeSafari
|
||||
#
|
||||
# IMPORTANT: Build web assets first using npm scripts before running docker-compose
|
||||
#
|
||||
# Usage:
|
||||
# Development: docker-compose up dev
|
||||
# Staging: docker-compose up staging
|
||||
# Production: docker-compose up production
|
||||
# Custom: BUILD_MODE=staging docker-compose up custom
|
||||
# Development: npm run build:web:build -- --mode development && docker-compose up dev
|
||||
# Test: npm run build:web:build -- --mode test && docker-compose up test
|
||||
# Production: npm run build:web:build -- --mode production && docker-compose up production
|
||||
# Custom: BUILD_MODE=test npm run build:web:build -- --mode test && docker-compose up custom
|
||||
#
|
||||
# Environment Variables:
|
||||
# BUILD_MODE: development, staging, or production (default: production)
|
||||
# BUILD_MODE: development, test, or production (default: production)
|
||||
# NODE_ENV: node environment (default: production)
|
||||
# VITE_PLATFORM: vite platform (default: web)
|
||||
# VITE_PWA_ENABLED: enable PWA (default: true)
|
||||
# VITE_DISABLE_PWA: disable PWA (default: false)
|
||||
# PORT: port to expose (default: 80 for production, 5173 for dev)
|
||||
# PORT: port to expose (default: 80 for production, 8080 for test)
|
||||
# ENV_FILE: environment file to use (default: .env.production)
|
||||
#
|
||||
# See .env files for application-specific configuration
|
||||
# VITE_APP_SERVER: Application server URL
|
||||
# VITE_DEFAULT_ENDORSER_API_SERVER: Endorser API server URL
|
||||
# Note: For development, use npm run build:web directly (no Docker needed)
|
||||
|
||||
version: '3.8'
|
||||
|
||||
@@ -31,9 +28,6 @@ x-defaults: &defaults
|
||||
args:
|
||||
BUILD_MODE: ${BUILD_MODE:-production}
|
||||
NODE_ENV: ${NODE_ENV:-production}
|
||||
VITE_PLATFORM: ${VITE_PLATFORM:-web}
|
||||
VITE_PWA_ENABLED: ${VITE_PWA_ENABLED:-true}
|
||||
VITE_DISABLE_PWA: ${VITE_DISABLE_PWA:-false}
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost/health"]
|
||||
@@ -43,60 +37,23 @@ x-defaults: &defaults
|
||||
start_period: 40s
|
||||
|
||||
services:
|
||||
# Development service with hot reloading
|
||||
dev:
|
||||
# Test service for testing environment
|
||||
test:
|
||||
<<: *defaults
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
target: development
|
||||
target: test
|
||||
args:
|
||||
BUILD_MODE: development
|
||||
NODE_ENV: development
|
||||
VITE_PLATFORM: web
|
||||
VITE_PWA_ENABLED: true
|
||||
VITE_DISABLE_PWA: false
|
||||
BUILD_MODE: test
|
||||
NODE_ENV: test
|
||||
ports:
|
||||
- "${DEV_PORT:-5173}:5173"
|
||||
volumes:
|
||||
- .:/app
|
||||
- /app/node_modules
|
||||
- "${TEST_PORT:-8080}:80"
|
||||
environment:
|
||||
- NODE_ENV=development
|
||||
- VITE_PLATFORM=web
|
||||
- VITE_PWA_ENABLED=true
|
||||
- VITE_DISABLE_PWA=false
|
||||
- NODE_ENV=test
|
||||
- BUILD_MODE=test
|
||||
env_file:
|
||||
- ${DEV_ENV_FILE:-.env.development}
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:5173"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 40s
|
||||
|
||||
# Staging service for testing
|
||||
staging:
|
||||
<<: *defaults
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
target: staging
|
||||
args:
|
||||
BUILD_MODE: staging
|
||||
NODE_ENV: staging
|
||||
VITE_PLATFORM: web
|
||||
VITE_PWA_ENABLED: true
|
||||
VITE_DISABLE_PWA: false
|
||||
ports:
|
||||
- "${STAGING_PORT:-8080}:80"
|
||||
environment:
|
||||
- NODE_ENV=staging
|
||||
- VITE_PLATFORM=web
|
||||
- VITE_PWA_ENABLED=true
|
||||
- VITE_DISABLE_PWA=false
|
||||
env_file:
|
||||
- ${STAGING_ENV_FILE:-.env.staging}
|
||||
- ${TEST_ENV_FILE:-.env.test}
|
||||
|
||||
# Production service
|
||||
production:
|
||||
@@ -108,16 +65,11 @@ services:
|
||||
args:
|
||||
BUILD_MODE: production
|
||||
NODE_ENV: production
|
||||
VITE_PLATFORM: web
|
||||
VITE_PWA_ENABLED: true
|
||||
VITE_DISABLE_PWA: false
|
||||
ports:
|
||||
- "${PROD_PORT:-80}:80"
|
||||
environment:
|
||||
- NODE_ENV=production
|
||||
- VITE_PLATFORM=web
|
||||
- VITE_PWA_ENABLED=true
|
||||
- VITE_DISABLE_PWA=false
|
||||
- BUILD_MODE=production
|
||||
env_file:
|
||||
- ${PROD_ENV_FILE:-.env.production}
|
||||
|
||||
@@ -131,17 +83,12 @@ services:
|
||||
args:
|
||||
BUILD_MODE: production
|
||||
NODE_ENV: production
|
||||
VITE_PLATFORM: web
|
||||
VITE_PWA_ENABLED: true
|
||||
VITE_DISABLE_PWA: false
|
||||
ports:
|
||||
- "${SSL_PORT:-443}:443"
|
||||
- "${HTTP_PORT:-80}:80"
|
||||
environment:
|
||||
- NODE_ENV=production
|
||||
- VITE_PLATFORM=web
|
||||
- VITE_PWA_ENABLED=true
|
||||
- VITE_DISABLE_PWA=false
|
||||
- BUILD_MODE=production
|
||||
env_file:
|
||||
- ${PROD_ENV_FILE:-.env.production}
|
||||
volumes:
|
||||
@@ -164,16 +111,11 @@ services:
|
||||
args:
|
||||
BUILD_MODE: ${BUILD_MODE:-production}
|
||||
NODE_ENV: ${NODE_ENV:-production}
|
||||
VITE_PLATFORM: ${VITE_PLATFORM:-web}
|
||||
VITE_PWA_ENABLED: ${VITE_PWA_ENABLED:-true}
|
||||
VITE_DISABLE_PWA: ${VITE_DISABLE_PWA:-false}
|
||||
ports:
|
||||
- "${CUSTOM_PORT:-8080}:${CUSTOM_INTERNAL_PORT:-80}"
|
||||
environment:
|
||||
- NODE_ENV=${NODE_ENV:-production}
|
||||
- VITE_PLATFORM=${VITE_PLATFORM:-web}
|
||||
- VITE_PWA_ENABLED=${VITE_PWA_ENABLED:-true}
|
||||
- VITE_DISABLE_PWA=${VITE_DISABLE_PWA:-false}
|
||||
- BUILD_MODE=${BUILD_MODE:-production}
|
||||
env_file:
|
||||
- ${CUSTOM_ENV_FILE:-.env.production}
|
||||
healthcheck:
|
||||
|
||||
Reference in New Issue
Block a user