-
Notifications
You must be signed in to change notification settings - Fork 0
Grafana Env 추가 및 배포 스크립트 수정 #243
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -80,7 +80,7 @@ wait_healthy() { | |||||
| rollback() { | ||||||
| echo "[롤백] 이전 컨테이너로 복구 중..." | ||||||
| cd "$COMPOSE_DIR" | ||||||
| docker compose up -d | ||||||
| docker compose up -d snackgame-server | ||||||
| set_drain false | ||||||
| echo "[롤백] 완료" | ||||||
| exit 1 | ||||||
|
|
@@ -106,7 +106,7 @@ docker compose pull | |||||
|
|
||||||
|
|
||||||
| echo "[배포] 컨테이너 교체 중..." | ||||||
| docker compose up -d || rollback | ||||||
| docker compose up -d snackgame-server || rollback | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. PR 제목에 "Grafana Env 추가"가 언급되어 있으나,
Suggested change
|
||||||
|
|
||||||
|
|
||||||
| wait_healthy || rollback | ||||||
|
|
||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
현재의
rollback방식은 실제 이전 이미지 버전으로의 복구를 수행하지 못하는 한계가 있습니다. 105번 라인에서docker compose pull이 이미 수행되었기 때문에, 여기서docker compose up을 다시 실행하더라도 로컬에 받아진 최신(문제가 발생한) 이미지를 그대로 사용하게 됩니다. 진정한 롤백을 위해서는 배포 전의 이미지 ID나 태그를 저장해두었다가 복구 시 해당 버전을 명시하여 실행하는 로직이 필요합니다. 또한, 배포 시와 마찬가지로--no-deps옵션을 추가하여 의도치 않은 서비스 재시작을 방지하는 것이 좋습니다.