Move sms.ir template IDs out of env into settings so SuperAdmin can manage them, and record every outbound SMS status in notifications.
87 lines
2.9 KiB
Bash
87 lines
2.9 KiB
Bash
# Environment Configuration
|
|
|
|
NODE_ENV=development
|
|
PORT=3000
|
|
MONGO_URI=mongodb://localhost:27017/teaching_institution_db
|
|
|
|
# Authentication JWT
|
|
JWT_ACCESS_SECRET=your_super_secret_access_token_key_change_me
|
|
JWT_REFRESH_SECRET=your_super_secret_refresh_token_key_change_me
|
|
JWT_ACCESS_EXPIRES_IN=15m
|
|
JWT_REFRESH_EXPIRES_IN=7d
|
|
|
|
# Localization & File Uploads
|
|
DEFAULT_LANG=fa
|
|
CORS_ORIGIN=*
|
|
UPLOAD_PATH=uploads
|
|
|
|
# -----------------------------------------------------------------------------
|
|
# S3-compatible object storage
|
|
# Local default: MinIO (docker-compose)
|
|
# Production (SeaweedFS): set SERVICE_* / AWS_* from your host, or set S3_* directly
|
|
# -----------------------------------------------------------------------------
|
|
# Local MinIO example:
|
|
S3_ENDPOINT=http://localhost:9000
|
|
S3_REGION=us-east-1
|
|
S3_ACCESS_KEY=minioadmin
|
|
S3_SECRET_KEY=minioadmin
|
|
|
|
# SeaweedFS live example (preferred aliases also work without S3_*):
|
|
# Use the public HTTPS URL (SERVICE_URL_S3). Never use plain http:// for the public host —
|
|
# Coolify/Traefik returns HTTP 307 and AWS SDK PutObject cannot follow it.
|
|
# Do NOT use :8333 from outside the SeaweedFS network (often refused).
|
|
# S3_ENDPOINT=https://s3.game-no.ir
|
|
# SERVICE_URL_S3=https://s3.game-no.ir
|
|
# SERVICE_USER_S3=...
|
|
# SERVICE_PASSWORD_S3=...
|
|
# AWS_ACCESS_KEY_ID=${SERVICE_USER_S3}
|
|
# AWS_SECRET_ACCESS_KEY=${SERVICE_PASSWORD_S3}
|
|
#
|
|
# File uploads: multer uses MEMORY storage and streams the buffer straight to the
|
|
# S3 temp bucket. No Coolify persistent volume / uploads folder is required for this.
|
|
|
|
S3_TEMP_BUCKET=temp
|
|
S3_CERTIFICATES_BUCKET=certificates
|
|
S3_DOCUMENTS_BUCKET=documents
|
|
S3_STORAGE_BUCKET=certificates
|
|
S3_FORCE_PATH_STYLE=true
|
|
SIGNED_URL_EXPIRES_IN=900
|
|
# Private by default — set true only if a bucket is publicly readable
|
|
S3_CERTIFICATES_PUBLIC=false
|
|
S3_DOCUMENTS_PUBLIC=false
|
|
# Optional public CDN/base URL used only when a bucket is public
|
|
S3_PUBLIC_BASE_URL=
|
|
|
|
# Optional SeaweedFS admin console (bucket management UI)
|
|
# SERVICE_URL_ADMIN=https://admin-s3.game-no.ir
|
|
# SERVICE_URL_ADMIN_23646=https://admin-s3.game-no.ir:23646
|
|
# SERVICE_USER_ADMIN=...
|
|
# SERVICE_PASSWORD_ADMIN=...
|
|
# SEAWEED_USER_ADMIN=${SERVICE_USER_ADMIN}
|
|
# SEAWEED_PASSWORD_ADMIN=${SERVICE_PASSWORD_ADMIN}
|
|
|
|
# SMTP Email Configuration
|
|
SMTP_HOST=smtp.mailtrap.io
|
|
SMTP_PORT=2525
|
|
SMTP_USER=your_smtp_user
|
|
SMTP_PASS=your_smtp_password
|
|
EMAIL_FROM=no-reply@institution.com
|
|
|
|
# SMS Provider Configuration (sms.ir)
|
|
SMS_ENABLED=false
|
|
SMS_PANEL_TOKEN=your_sms_ir_api_key
|
|
SMS_SENDER_NUMBER=10001000
|
|
# SMS verify template IDs are stored in the database (SuperAdmin → Settings).
|
|
|
|
# Bale Messenger Bot Token
|
|
BALE_BOT_TOKEN=mock_bale_bot_token
|
|
|
|
# SuperAdmin bootstrap (created automatically in production)
|
|
# Set SUPERADMIN_ENABLED=false to deactivate the bootstrap SuperAdmin and block login
|
|
SUPERADMIN_ENABLED=true
|
|
SUPERADMIN_USERNAME=
|
|
SUPERADMIN_PASSWORD=
|
|
SUPERADMIN_EMAIL=
|
|
SUPERADMIN_NATIONAL_ID=0000000000
|
|
SUPERADMIN_PHONE=09000000000
|