apps/nextjs-app/.env.example
# your public origin for generate full url, required
PUBLIC_ORIGIN=https://app.teable.io
# secret key for jwt and session and share, required
SECRET_KEY=defaultSecretKey
# storage provider local | minio | s3, default is local
BACKEND_STORAGE_PROVIDER=local
# s3 cloud storage
BACKEND_STORAGE_S3_REGION=us-east-2
BACKEND_STORAGE_S3_ENDPOINT=https://s3.us-east-2.amazonaws.com
# s3 internal endpoint, optional
BACKEND_STORAGE_S3_INTERNAL_ENDPOINT=https://s3.us-east-2.amazonaws-internal.com
BACKEND_STORAGE_S3_ACCESS_KEY=your_access_key
BACKEND_STORAGE_S3_SECRET_KEY=your_secret_key
# minio storage config
BACKEND_STORAGE_PUBLIC_BUCKET=public-bucket
BACKEND_STORAGE_PRIVATE_BUCKET=private-bucket
BACKEND_STORAGE_MINIO_ENDPOINT=minio.example.com
# minio internal endpoint, optional
BACKEND_STORAGE_MINIO_INTERNAL_ENDPOINT=internal-server-name
BACKEND_STORAGE_MINIO_PORT=443
# minio internal port, optional
BACKEND_STORAGE_MINIO_INTERNAL_PORT=9000
BACKEND_STORAGE_MINIO_USE_SSL=true
BACKEND_STORAGE_MINIO_ACCESS_KEY=access-key
BACKEND_STORAGE_MINIO_SECRET_KEY=secrect-key
# storage prefix, default is PUBLIC_ORIGIN, if you want to use minio storage, you need to set this value
STORAGE_PREFIX=http://localhost:3000
# cache provider sqlite | memory | redis, default is sqlite
BACKEND_CACHE_PROVIDER=sqlite
# your redis cache connection uri
BACKEND_CACHE_REDIS_URI=redis://default:teable@127.0.0.1:6379/0
# set metrics id, if you want to use microsoft clarity
MICROSOFT_CLARITY_ID=your-metrics-id
# set umami id and url, if you want to use umami analytics
UMAMI_WEBSITE_ID=your-umami-website-id
UMAMI_URL=https://umami.example.com/script.js
# The spaceId where your template base is located, it is the basic info of template center operation
TEMPLATE_SPACE_ID=your-template-space-id
# template site link, you need to set the current value to enable create from template
TEMPLATE_SITE_LINK=https://template.teable.io
# app port, default is 3000
PORT=3000
# fatal | error | warn | info | debug | trace default is info
LOG_LEVEL=info
# enable logging for 4xx errors, default is false
ENABLE_GLOBAL_ERROR_LOGGING=true
# DATABASE_URL, required
PRISMA_DATABASE_URL=postgresql://teable:teable@127.0.0.1:5432/teable
# for external database access
PUBLIC_DATABASE_PROXY=127.0.0.1:5432
# disable api doc, default is false
API_DOC_DISENABLED=false
# disable record history, default is false
RECORD_HISTORY_DISABLED=false
# Social signin providers
# github
BACKEND_GITHUB_CLIENT_ID=github_client_id
BACKEND_GITHUB_CLIENT_SECRET=github_client_secret
# google
BACKEND_GOOGLE_CLIENT_ID=google_client_id
BACKEND_GOOGLE_CLIENT_SECRET=google_client_secret
BACKEND_GOOGLE_CALLBACK_URL=https://app.teable.io/api/auth/google/callback
#oidc example google
BACKEND_OIDC_CLIENT_ID=google_client_id
BACKEND_OIDC_CLIENT_SECRET=google_client_secret
BACKEND_OIDC_CALLBACK_URL=https://app.teable.io/api/auth/oidc/callback
BACKEND_OIDC_USER_INFO_URL=https://openidconnect.googleapis.com/v1/userinfo
BACKEND_OIDC_TOKEN_URL=https://oauth2.googleapis.com/token
BACKEND_OIDC_AUTHORIZATION_URL=https://accounts.google.com/o/oauth2/auth
BACKEND_OIDC_ISSUER=https://accounts.google.com
BACKEND_OIDC_OTHER={"scope": ["email", "profile"]}
# separated by ','
SOCIAL_AUTH_PROVIDERS=github,google,oidc
# email configs
BACKEND_MAIL_HOST=example@gmail.com
BACKEND_MAIL_PORT=465
BACKEND_MAIL_SECURE=true
BACKEND_MAIL_SENDER=noreply@company.com
BACKEND_MAIL_SENDER_NAME=noreply
BACKEND_MAIL_AUTH_USER=username
BACKEND_MAIL_AUTH_PASS=usertoken
# session expires in, default is 7d
BACKEND_SESSION_EXPIRES_IN=7d
# session secret, default is SECRET_KEY
BACKEND_SESSION_SECRET=your_session_secret
# jwt expires in, default is 20d
BACKEND_JWT_EXPIRES_IN=20d
# jwt secret, default is SECRET_KEY
BACKEND_JWT_SECRET=your_jwt_secret
# reset password email expires in, default is 30m
BACKEND_RESET_PASSWORD_EMAIL_EXPIRES_IN=30m
# ↓↓↓↓↓↓↓↓ limitaions, time unit is ms ↓↓↓↓↓↓↓↓
# max copy cells in one request
MAX_COPY_CELLS=50000
# max reset cells in one request
MAX_RESET_CELLS=10000
# max paste cells in one request
MAX_PASTE_CELLS=10000
# max fetch rows in one request
MAX_READ_ROWS=10000
# max delete rows in one request
MAX_DELETE_ROWS=1000
# max update cells in one request
MAX_SYNC_UPDATE_CELLS=10000
# max differet group, if exceed this value, the group will be ignored
MAX_GROUP_POINTS=5000
# Represents how many cells are counted and stored at once, The larger the value, the larger the memory overhead
CALC_CHUNK_SIZE=1000
# depends on your cpu and db performance
ESTIMATE_CALC_CEL_PER_MS=3
# transform time for covert field, delete table etc., when your table come to large this need be longer
BIG_TRANSACTION_TIMEOUT=600000
# the maximum number of base db connections per role, default is 20
DEFAULT_MAX_BASE_DB_CONNECTIONS=20
# the maxium row limit when space has no credit, ignore it when you don't want to limit it
MAX_FREE_ROW_LIMIT=100000
# the undo redo stack size, default is 200
MAX_UNDO_STACK_SIZE=200
# the undo redo expiration time, default is 24 hours (in seconds)
UNDO_EXPIRATION_TIME=86400
# cloud 2G, default unlimited
MAX_ATTACHMENT_UPLOAD_SIZE=2147483648
# cloud 100m, default unlimited
MAX_OPENAPI_ATTACHMENT_UPLOAD_SIZE=104857600
# No need to modify it manually, it will be generated automatically when you package the image.
NEXT_PUBLIC_BUILD_VERSION=x.x.x
#######################################################################################
# 1. BUILD ENVIRONMENT - Consumed by next.config.mjs during build and development #
#######################################################################################
NEXT_BUILD_ENV_OUTPUT=classic
NEXT_BUILD_ENV_SOURCEMAPS=false
NEXT_BUILD_ENV_LINT=false
NEXT_BUILD_ENV_TYPECHECK=false
NEXT_BUILD_ENV_CSP=true
NEXT_BUILD_ENV_SENTRY_ENABLED=false
NEXT_BUILD_ENV_SENTRY_UPLOAD_DRY_RUN=true
NEXT_BUILD_ENV_SENTRY_DEBUG=false
NEXT_BUILD_ENV_SENTRY_TRACING=false
# enable nextjs image optimization
NEXT_ENV_IMAGES_ALL_REMOTE=true