-
Notifications
You must be signed in to change notification settings - Fork 0
운영 배포(OCI drain 옵션 수정) #239
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
7fe3a3b
b2d0eb4
36fac75
f71c8d4
08e0eba
fee6688
0a6e22f
2c39b30
63435f5
996782a
1e8247f
f287e2b
b0e08cc
664263f
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 |
|---|---|---|
|
|
@@ -36,16 +36,20 @@ set_drain() { | |
| --network-load-balancer-id "$NLB_ID" \ | ||
| --backend-set-name snackgame-http \ | ||
| --backend-name "$HTTP_BACKEND" \ | ||
| --is-drain "$is_drain" \ | ||
| --wait-for-state SUCCEEDED | ||
| --is-drain "$is_drain" | ||
|
|
||
| oci nlb backend update \ | ||
| --auth instance_principal \ | ||
| --network-load-balancer-id "$NLB_ID" \ | ||
| --backend-set-name snackgame-https \ | ||
| --backend-name "$HTTPS_BACKEND" \ | ||
| --is-drain "$is_drain" \ | ||
| --wait-for-state SUCCEEDED | ||
| --is-drain "$is_drain" | ||
|
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. |
||
|
|
||
|
|
||
| if [ "$is_drain" = "true" ]; then | ||
|
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. 현재 로직은 롤링 배포 환경에서 이전 서버가 아직 NLB에 복구되지 않은 상태에서 다음 서버의 배포(및 드레인)가 시작되면 전체 서비스 가용성에 영향을 줄 수 있습니다. |
||
| echo "[NLB] 드레인 적용 대기 중 (10초)..." | ||
| sleep 10 | ||
| fi | ||
| } | ||
|
|
||
|
|
||
|
|
||
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.
oci nlb backend update명령에서--wait-for-state SUCCEEDED와--force옵션을 제거하면 두 가지 주요 위험이 발생합니다.409 Conflict오류가 발생할 수 있습니다. OCI API는 일반적으로 동일 리소스에 대한 병렬 수정을 허용하지 않습니다.--force옵션이 없으면 CLI가 특정 상황에서 사용자 확인을 요청할 수 있어, 비대화형(non-interactive) 환경에서 스크립트가 중단될 수 있습니다.가급적이면 해당 옵션들을 유지하여 안정성을 확보하는 것이 좋습니다.