- application-prod.yml을 .gitignore에서 제거, 환경변수 참조 방식으로 코드에 포함 - deploy.yml에 DB_PASSWORD secret 추가 - systemd에서 -Dspring.config.additional-location 제거 - 서버 외부 application-prod.yml 의존 해소
26 lines
549 B
Desktop File
26 lines
549 B
Desktop File
[Unit]
|
|
Description=KCG Monitoring Backend
|
|
After=network.target
|
|
|
|
[Service]
|
|
Type=simple
|
|
User=root
|
|
Group=root
|
|
WorkingDirectory=/devdata/services/kcg/backend
|
|
EnvironmentFile=-/devdata/services/kcg/backend/.env
|
|
ExecStart=/usr/lib/jvm/java-21-openjdk-21.0.10.0.7-1.el9.x86_64/bin/java \
|
|
-Xms2g -Xmx4g \
|
|
-Dspring.profiles.active=prod \
|
|
-jar /devdata/services/kcg/backend/kcg.jar
|
|
|
|
Restart=on-failure
|
|
RestartSec=10
|
|
TimeoutStopSec=30
|
|
|
|
StandardOutput=journal
|
|
StandardError=journal
|
|
SyslogIdentifier=kcg-backend
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|