docker-compose.ymlâĸ1.88 kB
version: '3.8'
services:
mcp-abap-adt:
build:
context: .
dockerfile: Dockerfile
container_name: mcp-abap-adt-server
restart: unless-stopped
# HTTP transport on port 3000
ports:
- "3000:3000"
# Environment variables
environment:
- NODE_ENV=production
- MCP_HTTP_PORT=3000
- MCP_HTTP_HOST=0.0.0.0
# SAP connection (override with .env file or set here)
- SAP_URL=${SAP_URL}
- SAP_CLIENT=${SAP_CLIENT}
- SAP_AUTH_TYPE=${SAP_AUTH_TYPE}
- SAP_JWT_TOKEN=${SAP_JWT_TOKEN}
- SAP_USERNAME=${SAP_USERNAME}
- SAP_PASSWORD=${SAP_PASSWORD}
# Load environment from .env file
env_file:
- .env
# Volumes for persistence (optional)
volumes:
# Persist sessions
- ./data/sessions:/app/.sessions
# Persist locks
- ./data/locks:/app/.locks
# Persist cache
- ./data/cache:/app/cache
# Health check
healthcheck:
test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:3000/health"]
interval: 30s
timeout: 5s
retries: 3
start_period: 10s
# Resource limits (optional)
deploy:
resources:
limits:
cpus: '1.0'
memory: 1G
reservations:
cpus: '0.5'
memory: 512M
# Logging
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
# Optional: nginx reverse proxy
nginx:
image: nginx:alpine
container_name: mcp-abap-adt-nginx
restart: unless-stopped
ports:
- "80:80"
- "443:443"
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf:ro
# SSL certificates (if using HTTPS)
# - ./certs:/etc/nginx/certs:ro
depends_on:
- mcp-abap-adt
profiles:
- with-nginx
# Volumes
volumes:
sessions:
locks:
cache: