teableio/teable

View on GitHub
dockers/examples/docker-swarm/docker-compose.app.yml

Summary

Maintainability
Test Coverage
version: '3.9'

services:
  teable:
    image: ghcr.io/teableio/teable:latest
    deploy:
      replicas: 2
      restart_policy:
        condition: on-failure
      update_config:
        parallelism: 1
        delay: 10s
        order: start-first
    expose:
      - '3000'
    environment:
      - TZ=${TIMEZONE}
      - NEXT_ENV_IMAGES_ALL_REMOTE=true
      - PUBLIC_ORIGIN=${PUBLIC_ORIGIN}
      - PRISMA_DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB}
      - PUBLIC_DATABASE_PROXY=${PUBLIC_DATABASE_PROXY}
      - BACKEND_CACHE_PROVIDER=redis
      - BACKEND_CACHE_REDIS_URI=redis://default:${POSTGRES_PASSWORD}@${REDIS_HOST}:${REDIS_PORT}/${REDIS_DB}
      - BACKEND_STORAGE_PROVIDER=${BACKEND_STORAGE_PROVIDER}
      - BACKEND_STORAGE_PUBLIC_BUCKET=${BACKEND_STORAGE_PUBLIC_BUCKET}
      - BACKEND_STORAGE_PRIVATE_BUCKET=${BACKEND_STORAGE_PRIVATE_BUCKET}
      - BACKEND_STORAGE_MINIO_ENDPOINT=${BACKEND_STORAGE_MINIO_ENDPOINT}
      - BACKEND_STORAGE_MINIO_PORT=${BACKEND_STORAGE_MINIO_PORT}
      - BACKEND_STORAGE_MINIO_USE_SSL=${BACKEND_STORAGE_MINIO_USE_SSL}
      - BACKEND_STORAGE_MINIO_ACCESS_KEY=${MINIO_ACCESS_KEY}
      - BACKEND_STORAGE_MINIO_SECRET_KEY=${MINIO_SECRET_KEY}
      - STORAGE_PREFIX=${STORAGE_PREFIX}
      # - BACKEND_MAIL_HOST=${BACKEND_MAIL_HOST}
      # - BACKEND_MAIL_PORT=${BACKEND_MAIL_PORT}
      # - BACKEND_MAIL_SECURE=${BACKEND_MAIL_SECURE}
      # - BACKEND_MAIL_SENDER=${BACKEND_MAIL_SENDER}
      # - BACKEND_MAIL_SENDER_NAME=${BACKEND_MAIL_SENDER_NAME}
      # - BACKEND_MAIL_AUTH_USER=${BACKEND_MAIL_AUTH_USER}
      # - BACKEND_MAIL_AUTH_PASS=${BACKEND_MAIL_AUTH_PASS}
    networks:
      - teable-swarm
    healthcheck:
      test: ['CMD', 'curl', '-f', 'http://localhost:3000/health']
      start_period: 5s
      interval: 5s
      timeout: 3s
      retries: 3