빌드 컨텍스트 변경에도 운영 frontend chunk 에 신규 라우트가 들어가지
않는 증상 발견. Kaniko/Docker layer cache 가 npm run build 단계를
잘못된 시점에 hit 하는 것으로 의심. GIT_SHA build-arg 를 npm run build
직전에 주입해 매 commit 마다 그 layer 부터 강제 invalidate.
또 진단 step 에 deploy 이미지 tag 표시 추가 — 새 image 로 갱신
됐는지 즉시 확인 가능.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
deployment/<name> selector 는 활성 ReplicaSet 만 봐서 새 ReplicaSet 의
CrashLoopBackOff pod 로그를 놓친다. label selector 로 모든 pod 를
순회하며 current + previous 로그 출력.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
backend-spring rollout 이 180초 timeout 으로 실패할 때, Gitea Actions
로그에는 timeout 메시지만 나오고 정작 Spring Boot 부팅 단계의 진짜
에러는 pod 안 stdout 에 갇혀 있어서 디버깅 불가.
- if: failure() 조건으로 마지막에 Diagnose step 추가
- kubectl get pods, describe, logs (current + previous), events 출력
- frontend 도 참고용 200줄 출력
- 모든 명령 || true 로 감싸서 진단 자체가 실패해도 다음 단계 진행
이 step 은 진짜 원인 파악되고 안정화되면 제거 예정.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>