Skip to content

Commit ffc20ac

Browse files
committed
refactor: CI/CD 스크립트 수정
1 parent a160628 commit ffc20ac

1 file changed

Lines changed: 4 additions & 7 deletions

File tree

.github/workflows/dev_deploy.yml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -97,10 +97,7 @@ jobs:
9797
# nohup: SSH 접속이 끊겨도 서버가 계속 실행되도록 함
9898
export $(grep -v '^#' .env | xargs)
9999
JAR_FILE=$(ls /home/${{ secrets.EC2_USERNAME }}/*.jar | grep -v -- '-plain.jar' | head -n 1)
100-
101-
# ✅ 'java -jar' 명령어에 직접 Redis 호스트 정보를 추가합니다.
102-
chmod +x /home/ubuntu/alarm-0.0.1-SNAPSHOT.jar
103-
chmod +x /home/ubuntu/.env
104-
cd /home/ubuntu
105-
sudo nohup java -jar alarm-0.0.1-SNAPSHOT.jar &
106-
echo "애플리케이션을 성공적으로 시작했습니다."
100+
101+
# ✅ 옵션(--spring.redis.host)을 JAR 파일 이름 뒤로 이동
102+
nohup /usr/bin/java -jar $JAR_FILE --spring.redis.host=localhost > app.log 2>&1 &
103+

0 commit comments

Comments
 (0)