Skip to content

πŸ’« feat: CI/CD μ‹€ν–‰ μ‹œκ°„ μ΅œμ ν™” 및 μ›Œν¬ν”Œλ‘œμš° ꡬ쑰 κ°œμ„ #7

Merged
JoonKyoLee merged 4 commits into
developfrom
feature/cicd-performance-optimization
Jul 14, 2026
Merged

πŸ’« feat: CI/CD μ‹€ν–‰ μ‹œκ°„ μ΅œμ ν™” 및 μ›Œν¬ν”Œλ‘œμš° ꡬ쑰 κ°œμ„ #7
JoonKyoLee merged 4 commits into
developfrom
feature/cicd-performance-optimization

Conversation

@JoonKyoLee

@JoonKyoLee JoonKyoLee commented Jul 14, 2026

Copy link
Copy Markdown
Member

#️⃣ Issue Number

πŸ“ μš”μ•½(Summary)

  • PR μ „μš© CI 검증 νλ¦„μœΌλ‘œ μ‘°μ •ν•΄ pull_requestμ—μ„œλ§Œ CIκ°€ μ‹€ν–‰λ˜λ„λ‘ λ³€κ²½ν–ˆμŠ΅λ‹ˆλ‹€.
  • PR CIμ—μ„œλŠ” ./gradlew test만 μˆ˜ν–‰ν•˜λ„λ‘ μ •λ¦¬ν•˜κ³ , bootJar 및 Docker build 단계λ₯Ό μ œκ±°ν•΄ λΉ λ₯Έ ν”Όλ“œλ°±μ— μ§‘μ€‘ν•˜λ„λ‘ κ΅¬μ„±ν–ˆμŠ΅λ‹ˆλ‹€.
  • deploy workflowμ—μ„œλŠ” 동일 SHA 이미지가 ECR에 이미 μ‘΄μž¬ν•˜λŠ” 경우 build/pushλ₯Ό μƒλž΅ν•˜κ³  deploy만 μ§„ν–‰ν•˜λ„λ‘ μˆ˜μ •ν–ˆμŠ΅λ‹ˆλ‹€.
  • deploy workflowμ—μ„œ bootJar 단계λ₯Ό μ œκ±°ν•˜κ³ , Docker buildκ°€ μ‹€μ œ μ‚°μΆœλ¬Ό 검증 역할을 λ‹΄λ‹Ήν•˜λ„λ‘ 쀑볡 λΉŒλ“œ ꡬ쑰λ₯Ό μ •λ¦¬ν–ˆμŠ΅λ‹ˆλ‹€.
  • immutable tag μ „λž΅μ€ μœ μ§€ν•˜λ©΄μ„œ rerun μ‹œ 이미지 μž¬ν‘Έμ‹œ 좩돌이 λ°œμƒν•˜μ§€ μ•Šλ„λ‘ μ›Œν¬ν”Œλ‘œμš°λ₯Ό λ³΄μ™„ν–ˆμŠ΅λ‹ˆλ‹€.

πŸ“ 리뷰 μš”μ²­μ‚¬ν•­

  • PR 단계와 배포 λ‹¨κ³„μ˜ μ±…μž„μ„ 뢄리해 CIλŠ” λΉ λ₯Έ 검증, deployλŠ” μ‹€μ œ μ‚°μΆœλ¬Ό λΉŒλ“œ 및 배포에 μ§‘μ€‘ν•˜λ„λ‘ μ‘°μ •ν–ˆμŠ΅λ‹ˆλ‹€.
  • immutable SHA νƒœκ·Έ μ „λž΅μ€ μœ μ§€ν•˜λ©΄μ„œ 동일 컀밋 μž¬μ‹€ν–‰ μ‹œ κΈ°μ‘΄ 이미지λ₯Ό μž¬μ‚¬μš©ν•˜λ„λ‘ κ΅¬μ„±ν–ˆμŠ΅λ‹ˆλ‹€.
  • 쀑볡 μ‹€ν–‰κ³Ό 쀑볡 λΉŒλ“œ λΉ„μš©μ„ μ€„μ΄λŠ” λ°©ν–₯으둜 μ›Œν¬ν”Œλ‘œμš°λ₯Ό λ‹¨μˆœν™”ν–ˆμŠ΅λ‹ˆλ‹€.

πŸ’» ν…ŒμŠ€νŠΈ κ²°κ³Ό

  • μ›Œν¬ν”Œλ‘œμš° ꡬ쑰 λ³€κ²½ κΈ°μ€€μœΌλ‘œ 둜컬 μ½”λ“œ μˆ˜μ • λ°˜μ˜μ„ μ™„λ£Œν–ˆμŠ΅λ‹ˆλ‹€.
  • μ‹€μ œ PR CI μ‹€ν–‰ μ‹œκ°„ λΉ„κ΅λŠ” PR 생성 ν›„ GitHub Actions μ‹€ν–‰ κ²°κ³Όλ₯Ό κΈ°μ€€μœΌλ‘œ 정리 μ˜ˆμ •μž…λ‹ˆλ‹€.
  • 동일 SHA μž¬μ‹€ν–‰ μ‹œ ECR immutable tag 좩돌이 λ°œμƒν•˜λ˜ ꡬ쑰λ₯Ό build/push skip λ°©μ‹μœΌλ‘œ λ³΄μ™„ν–ˆμŠ΅λ‹ˆλ‹€.

⏱️ μ‹€ν–‰ μ‹œκ°„ 비ꡐ

  • λ³€κ²½ μ „
스크란샷 2026-07-15 α„‹α…©α„Œα…₯ᆫ 12 01 09
  • λ³€κ²½ ν›„
스크란샷 2026-07-15 α„‹α…©α„Œα…₯ᆫ 12 01 17
ꡬ뢄 λ³€κ²½ μ „ λ³€κ²½ ν›„
PR CI μ‹€ν–‰ μ‹œκ°„ 2λΆ„ 57초 46초 (μ•½ 74% 단좕)
  • PR CIμ—μ„œ bootJar 및 Docker build 단계λ₯Ό μ œκ±°ν•˜κ³  test만 μˆ˜ν–‰ν•˜λ„λ‘ μ‘°μ •ν•˜λ©΄μ„œ μ‹€ν–‰ μ‹œκ°„μ΄ 2λΆ„ 57μ΄ˆμ—μ„œ 46초둜 κ°μ†Œν•΄, μ•½ 74% 단좕 효과λ₯Ό ν™•μΈν–ˆμŠ΅λ‹ˆλ‹€.

πŸ“Œ 포인트

  • PRμ—μ„œλŠ” ν…ŒμŠ€νŠΈλ§Œ μˆ˜ν–‰ν•˜κ³ , μ‹€μ œ λΉŒλ“œ/λ°°ν¬λŠ” deploy workflowκ°€ λ‹΄λ‹Ήν•˜λ„λ‘ 역할을 λΆ„λ¦¬ν–ˆμŠ΅λ‹ˆλ‹€.
  • 동일 컀밋 μž¬μ‹€ν–‰ μ‹œμ—λ„ immutable tag μ „λž΅μ„ μœ μ§€ν•˜λ©΄μ„œ 배포 μž¬μ‹œλ„κ°€ κ°€λŠ₯ν•˜λ„λ‘ κ΅¬μ„±ν–ˆμŠ΅λ‹ˆλ‹€.
  • λΆˆν•„μš”ν•œ CI 쀑볡 μ‹€ν–‰κ³Ό bootJar 쀑볡 μˆ˜ν–‰μ„ 쀄여 ν”Όλ“œλ°± 루프와 배포 μ‹œκ°„μ„ ν•¨κ»˜ κ°œμ„ ν•˜λŠ” λ°©ν–₯으둜 μ •λ¦¬ν–ˆμŠ΅λ‹ˆλ‹€.

✍️ 회고

  • μžλ™ν™” νŒŒμ΄ν”„λΌμΈμ„ λ‹¨μˆœνžˆ λ™μž‘μ‹œν‚€λŠ” μˆ˜μ€€μ—μ„œ λ‚˜μ•„κ°€, μ‹€ν–‰ μ‹œκ°„κ³Ό μž¬μ‹€ν–‰ μ•ˆμ •μ„±κΉŒμ§€ κ³ λ €ν•˜λŠ” ꡬ쑰둜 λ‹€λ“¬μ—ˆμŠ΅λ‹ˆλ‹€.

Summary by CodeRabbit

  • CI/CD Improvements
    • Pull request checks now focus on running automated tests.
    • Development and production deployments avoid rebuilding or republishing container images when the matching image already exists.
    • Deployment workflows continue to run tests before deployment.

@JoonKyoLee JoonKyoLee self-assigned this Jul 14, 2026
@coderabbitai

coderabbitai Bot commented Jul 14, 2026

Copy link
Copy Markdown

Review Change Stack

πŸ“ Walkthrough

Walkthrough

The workflows now run tests separately from packaging, restrict CI to pull requests, and check ECR for existing SHA-tagged images before conditionally building and pushing development or production Docker images.

Changes

CI/CD workflow optimization

Layer / File(s) Summary
Test-only CI workflow
.github/workflows/ci.yml
CI runs on pull requests with read-only contents permission and executes only ./gradlew test --no-daemon.
Conditional deployment image builds
.github/workflows/deploy-dev.yml, .github/workflows/deploy-prod.yml
Deployment workflows run tests, check for existing dev or prod SHA-tagged ECR images, and conditionally build and push missing images.

Estimated code review effort: 2 (Simple) | ~15 minutes

Sequence Diagram(s)

sequenceDiagram
  participant GitHubActions
  participant AmazonECR
  participant Docker
  GitHubActions->>AmazonECR: Check dev or prod SHA image tag
  AmazonECR-->>GitHubActions: Return image existence
  GitHubActions->>Docker: Build image when tag is absent
  Docker-->>GitHubActions: Provide built image
  GitHubActions->>AmazonECR: Push image when tag is absent
Loading

Possibly related issues

  • Issue 5 β€” Directly covers CI/CD optimization and prevents duplicate ECR builds and pushes for the same SHA.
  • Issue 3 β€” Covers the GitHub Actions testing, Docker, ECR, and deployment workflow changes updated here.
πŸš₯ Pre-merge checks | βœ… 5
βœ… Passed checks (5 passed)
Check name Status Explanation
Linked Issues check βœ… Passed The changes align with the linked CI/CD and ECR objectives by simplifying PR tests and skipping duplicate image builds on existing SHA tags.
Out of Scope Changes check βœ… Passed All changes stay within GitHub Actions workflow optimization and ECR deploy idempotency, with no unrelated code areas introduced.
Docstring Coverage βœ… Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check βœ… Passed The title clearly summarizes the main change: CI/CD runtime optimization and workflow restructuring.
Description check βœ… Passed The description matches the required template and covers the issue number, summary, review requests, and test results.
✨ Finishing Touches
πŸ“ Generate docstrings
  • Create stacked PR
  • Commit on current branch
πŸ§ͺ Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/cicd-performance-optimization

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

πŸ€– Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/deploy-dev.yml:
- Around line 54-66: Update the image-check steps in
.github/workflows/deploy-dev.yml lines 54-66 and
.github/workflows/deploy-prod.yml lines 54-66 so aws ecr describe-images
distinguishes a not-found response from other failures: set exists=false only
when the image is absent, and fail the step for authentication, throttling,
network, or other AWS errors while preserving exists=true for found images.
πŸͺ„ Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
βš™οΈ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 17eb03a7-5748-4563-9c1e-ed74ca9d7e87

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between 5bb99cb and c524cee.

πŸ“’ Files selected for processing (3)
  • .github/workflows/ci.yml
  • .github/workflows/deploy-dev.yml
  • .github/workflows/deploy-prod.yml

Comment thread .github/workflows/deploy-dev.yml
@JoonKyoLee JoonKyoLee merged commit 288773a into develop Jul 14, 2026
2 checks passed
@JoonKyoLee JoonKyoLee changed the title πŸ’« [feature] #4 - CI/CD μ‹€ν–‰ μ‹œκ°„ μ΅œμ ν™” 및 μ›Œν¬ν”Œλ‘œμš° ꡬ쑰 κ°œμ„  πŸ’« feat: CI/CD μ‹€ν–‰ μ‹œκ°„ μ΅œμ ν™” 및 μ›Œν¬ν”Œλ‘œμš° ꡬ쑰 κ°œμ„  Jul 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

πŸ’« [feature] CI/CD μ‹€ν–‰ μ‹œκ°„ μ΅œμ ν™” 및 μΊμ‹œ μ „λž΅ κ°œμ„ 

1 participant