Skip to content

chore(ci) : GCP_SA_KEY 제거 및 Docker 이미지 직접 전송 방식으로 배포 전환 - #159

Merged
chuuminggg merged 1 commit into
mainfrom
ci/deploy-without-gcp-sa-key
Jul 8, 2026
Merged

chore(ci) : GCP_SA_KEY 제거 및 Docker 이미지 직접 전송 방식으로 배포 전환#159
chuuminggg merged 1 commit into
mainfrom
ci/deploy-without-gcp-sa-key

Conversation

@chuuminggg

Copy link
Copy Markdown
Member

🔥ISSUE

Artifact Registry 경유(push/pull) 대신 CI에서 빌드한 이미지를
docker save로 압축해 SCP로 GCE VM에 전송 후 docker load 하도록 변경. 서비스 계정 키(GCP_SA_KEY) 의존성을 제거하고 SSH 키만으로 배포.

📒TODO

  • google-github-actions/auth, setup-gcloud, registry push 제거
  • 서버 내 docker login(GCP_SA_KEY) 및 docker pull 제거
  • docker-compose.prod.yml 이미지 참조를 로컬 태그(link-it-backend:latest)로 변경

📋REF

Artifact Registry 경유(push/pull) 대신 CI에서 빌드한 이미지를
docker save로 압축해 SCP로 GCE VM에 전송 후 docker load 하도록 변경.
서비스 계정 키(GCP_SA_KEY) 의존성을 제거하고 SSH 키만으로 배포.

- google-github-actions/auth, setup-gcloud, registry push 제거
- 서버 내 docker login(GCP_SA_KEY) 및 docker pull 제거
- docker-compose.prod.yml 이미지 참조를 로컬 태그(link-it-backend:latest)로 변경

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

@gemini-code-assist gemini-code-assist 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.

Code Review

This pull request updates the docker-compose.prod.yml file to simplify the backend service's image name by removing the GCP Artifact Registry path. The review feedback correctly points out that hardcoding the latest tag in a production environment can hinder deployment determinism and rollback stability, suggesting the use of an environment variable with a default fallback instead.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread docker-compose.prod.yml

app:
image: ${GCP_REGION}-docker.pkg.dev/${GCP_PROJECT_ID}/${GCP_REPOSITORY}/link-it-backend:latest
image: link-it-backend:latest

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

운영 환경(docker-compose.prod.yml)에서 latest 태그를 고정하여 사용하는 것은 배포의 결정성(determinism)을 저해하고, 장애 발생 시 특정 버전으로의 안정적인 롤백을 어렵게 만듭니다.

배포 시점에 특정 이미지 태그를 유연하게 지정할 수 있도록 환경 변수(예: ${IMAGE_TAG:-latest})를 사용하는 방식을 권장합니다.

    image: link-it-backend:${IMAGE_TAG:-latest}
References
  1. For environment-specific configurations, use environment variables with default values in YAML configuration files instead of hardcoding or commenting out values.

@chuuminggg
chuuminggg merged commit e36768b into main Jul 8, 2026
1 check passed
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.

1 participant