feat(deploy): A10 MVP W2-W4 容器化+nginx 单源+compose 编排骨架
platform-app/flowable-service Dockerfile(JRE21+非root+COPY 预构建 jar+健康探针);deploy/nginx.conf(单源:serve dist+反代 /api、/flowable);deploy/docker-compose.yml(4服务 postgres+platform-app+flowable-service+nginx,healthcheck/depends_on);deploy/.env.example(prod 密钥/DB env,fail-fast);deploy/systemd/*(D3 禁Docker客户兜底);deploy/README.md。验证:docker compose config 通过(4服务+插值);docker build 待 daemon(本机未起,已诚实标注)。验证揪修 flowable-service 双数据源 FLOWABLE_JDBC_*/BIZ_JDBC_* env 漏传。.gitignore 加 deploy/.env。W1 Flyway 下一批次:当前 compose 假定 DB 已置备,尚不能从零自举。 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
19
deploy/systemd/eip4-flowable.service
Normal file
19
deploy/systemd/eip4-flowable.service
Normal file
@@ -0,0 +1,19 @@
|
||||
# EIP4 flowable-service systemd 单元(A10 W4·D3 兜底)。
|
||||
# 安装同 eip4-platform.service:jar→/opt/eip4/flowable-service.jar,env→/etc/eip4/flowable.env。
|
||||
[Unit]
|
||||
Description=EIP4 flowable-service
|
||||
After=network-online.target
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
User=eip4
|
||||
Group=eip4
|
||||
EnvironmentFile=/etc/eip4/flowable.env
|
||||
Environment=SPRING_PROFILES_ACTIVE=prod
|
||||
ExecStart=/usr/bin/java -jar /opt/eip4/flowable-service.jar
|
||||
SuccessExitStatus=143
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
27
deploy/systemd/eip4-platform.service
Normal file
27
deploy/systemd/eip4-platform.service
Normal file
@@ -0,0 +1,27 @@
|
||||
# EIP4 platform-app systemd 单元(A10 W4·D3 兜底:禁 Docker 的客户用裸 jar + systemd)。
|
||||
# 安装:
|
||||
# sudo cp platform-app/target/platform-app-*.jar /opt/eip4/platform-app.jar
|
||||
# sudo install -d -o eip4 -g eip4 /opt/eip4 /var/lib/eip4/files
|
||||
# sudo cp deploy/.env.example /etc/eip4/platform.env # 改成真值,chmod 600
|
||||
# sudo cp deploy/systemd/eip4-platform.service /etc/systemd/system/
|
||||
# sudo systemctl daemon-reload && sudo systemctl enable --now eip4-platform
|
||||
[Unit]
|
||||
Description=EIP4 platform-app
|
||||
After=network-online.target
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
User=eip4
|
||||
Group=eip4
|
||||
# /etc/eip4/platform.env 提供 EIP4_AUTH_JWT_SECRET / EIP4_DB_* / SERVER_PORT 等(chmod 600)
|
||||
EnvironmentFile=/etc/eip4/platform.env
|
||||
Environment=SPRING_PROFILES_ACTIVE=prod
|
||||
Environment=EIP4_FILE_ROOT=/var/lib/eip4/files
|
||||
# JDK21 路径按宿主调整
|
||||
ExecStart=/usr/bin/java -jar /opt/eip4/platform-app.jar
|
||||
SuccessExitStatus=143
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user