Files
urbanLifeline/docker/kkfileView/docker-compose.yml
2026-02-11 14:14:15 +08:00

43 lines
1.2 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# ================================================
# KKFileView 文档预览服务
# ================================================
name: urbanlifeline
services:
# ====================== KKFileView 文档预览 ======================
kkfileview:
image: keking/kkfileview:latest
container_name: urban-lifeline-kkfileview
restart: unless-stopped
env_file:
- .env
networks:
- urban-lifeline
ports:
- "${KKFILEVIEW_PORT:-8012}:8012"
environment:
# 基础配置
KKFILEVIEW_PORT: 8012
# 新增:核心预览路径(从.env读取代理后的KKFileView完整域名
KK_BASE_URL: ${KKFILEVIEW_BASE_URL}
# 新增允许外部访问固定值0.0.0.0,无需修改)
SERVER_HOST: 0.0.0.0
# 存储配置(如果需要)
# STORAGE_TYPE: local
# STORAGE_PATH: /data
TZ: Asia/Shanghai
volumes:
- ${DATA_ROOT:-../volumes}/kkfileview/data:/data
- ${DATA_ROOT:-../volumes}/kkfileview/log:/opt/kkfileview/log
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8012/onlinePreview"]
interval: 30s
timeout: 20s
retries: 3
start_period: 30s
networks:
urban-lifeline:
external: true
name: urban-lifeline