Refactor Docker Compose examples and documentation
- Updated README.md to include new example files for minimal and production configurations with detailed instructions. - Added compose.production-alt.example.yml for an annotated production setup. - Introduced new example files: compose.minimal.example.yml, compose.production.example.yml, nginx.example.conf, and traefik.example.yml for better clarity and usability. - Removed outdated configuration files and consolidated documentation for OCR language support. - Adjusted Nginx and Traefik configurations to reflect best practices and added necessary comments for user guidance. - Minor formatting and consistency improvements across documentation files.
This commit is contained in:
parent
f6b45627e0
commit
8a84caa503
14 changed files with 175 additions and 821 deletions
49
docs/範例配置/traefik.example.yml
Normal file
49
docs/範例配置/traefik.example.yml
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
# ConvertX-CN + Traefik 配置
|
||||
# 適用於:使用 Traefik 作為反向代理
|
||||
#
|
||||
# 使用方式:
|
||||
# 1. 確保已有 Traefik 服務且建立 traefik-network
|
||||
# 2. 複製此檔案並重命名為 docker-compose.yml
|
||||
# 3. 將 YOUR_DOMAIN_HERE 替換為你的網域
|
||||
# 4. 將 YOUR_JWT_SECRET_HERE 替換為隨機字串
|
||||
# 5. docker compose up -d
|
||||
#
|
||||
# 必須修改的欄位:
|
||||
# - YOUR_JWT_SECRET_HERE
|
||||
# - YOUR_DOMAIN_HERE(共 2 處)
|
||||
|
||||
services:
|
||||
convertx:
|
||||
image: convertx/convertx-cn:latest
|
||||
container_name: convertx-cn
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- ./data:/app/data
|
||||
environment:
|
||||
# ⚠️ 必填:請更換為長且隨機的字串(至少 32 字元)
|
||||
- JWT_SECRET=YOUR_JWT_SECRET_HERE
|
||||
- TZ=Asia/Taipei
|
||||
- HTTP_ALLOWED=false
|
||||
- TRUST_PROXY=true
|
||||
- ACCOUNT_REGISTRATION=false
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
# HTTP 路由
|
||||
- "traefik.http.routers.convertx.rule=Host(`YOUR_DOMAIN_HERE`)"
|
||||
- "traefik.http.routers.convertx.entrypoints=web"
|
||||
- "traefik.http.routers.convertx.middlewares=https-redirect"
|
||||
# HTTPS 路由
|
||||
- "traefik.http.routers.convertx-secure.rule=Host(`YOUR_DOMAIN_HERE`)"
|
||||
- "traefik.http.routers.convertx-secure.entrypoints=websecure"
|
||||
- "traefik.http.routers.convertx-secure.tls=true"
|
||||
- "traefik.http.routers.convertx-secure.tls.certresolver=letsencrypt"
|
||||
# 服務
|
||||
- "traefik.http.services.convertx.loadbalancer.server.port=3000"
|
||||
# 中間件
|
||||
- "traefik.http.middlewares.https-redirect.redirectscheme.scheme=https"
|
||||
networks:
|
||||
- traefik-network
|
||||
|
||||
networks:
|
||||
traefik-network:
|
||||
external: true
|
||||
Loading…
Add table
Add a link
Reference in a new issue