Files
lab/.env.example
2026-09-21 13:17:14 +08:00

33 lines
1.2 KiB
Plaintext
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.
# =====================================================================
# 实验室预约与资源管理平台 - Docker Compose 环境变量示例
#
# 使用方式:
# cp .env.example .env # 复制后按需修改,docker compose 会自动读取 .env
# docker compose up -d --build
#
# 注意:.env 已在 .gitignore 中忽略,请勿把真实密码/密钥提交到仓库。
# =====================================================================
# ---------- 数据库(MariaDB) ----------
# 首次创建数据卷时生效;修改后如需重建,先执行 docker compose down -v
DB_NAME=lab
DB_USER=lab
DB_PASSWORD=lab123456
DB_ROOT_PASSWORD=root123456
# ---------- 后端 ----------
# JWT 签名密钥,长度必须 >= 32 字节;生产环境请替换为随机值
# 生成示例:openssl rand -base64 48
LAB_JWT_SECRET=lab-reservation-docker-secret-key-change-me-2026
# JVM 参数(容器内存较小可下调 -Xmx)
JAVA_OPTS=-Xms256m -Xmx512m
# ---------- 端口映射(宿主机端口) ----------
# 前端 Nginx 端口(默认 8088:rootless Podman 无法绑定 80 等特权端口)
WEB_PORT=8088
# 后端直连端口(调试用,前端经 Nginx 代理访问后端)
BACKEND_PORT=8080
# 数据目录
DATA_DIR=./mariadb_data