Skip to content

Comments

fix: 구글 로그인 쿠키 이슈 해결 (프록시 설정)#36

Merged
Parkchanyoung0710 merged 2 commits intodevelopfrom
fix/oauth-set-cookie
Feb 5, 2026
Merged

fix: 구글 로그인 쿠키 이슈 해결 (프록시 설정)#36
Parkchanyoung0710 merged 2 commits intodevelopfrom
fix/oauth-set-cookie

Conversation

@Parkchanyoung0710
Copy link
Contributor

@Parkchanyoung0710 Parkchanyoung0710 commented Feb 5, 2026

변경된 내용

  • 구글 로그인 쿠키 이슈 해결

Summary by CodeRabbit

  • 개선사항

    • CORS 원본 검증 로직을 개선해 Vercel 도메인(.vercel.app) 자동 허용
    • 프록시 신뢰 설정 추가로 리버스 프록시 환경에서 안정성 향상
    • 불필요 주석 제거 등 코드 정리로 가독성 개선
  • 테스트

    • 인증 관련 단위 테스트 파일이 제거되어 테스트 범위 변경됨

@coderabbitai
Copy link

coderabbitai bot commented Feb 5, 2026

📝 Walkthrough

Walkthrough

src/main.ts에서 NestExpressApplication을 명시적 제네릭 타입으로 사용하고 trust proxy를 1로 설정했으며, CORS 원본 검증 로직을 변경해 .vercel.app으로 끝나는 origin을 허용하도록 수정했습니다. 또한 src/auth/service/auth.service.spec.ts 테스트 파일이 삭제되었습니다.

Changes

Cohort / File(s) Summary
애플리케이션 초기화 및 CORS 구성
src/main.ts
NestExpressApplication을 제네릭으로 지정해 NestFactory.create 호출 타입을 변경, app.set('trust proxy', 1) 추가, CORS origin 체크 로직을 수정하여 .vercel.app 도메인을 허용하게 함.
테스트 삭제
src/auth/service/auth.service.spec.ts
AuthService 로그인 관련 단위 테스트 파일 전체 삭제: 성공/실패 케이스 및 토큰 생성/삭제 동작을 검증하던 테스트들이 제거됨.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 메인에 깃든 작은 변화,
프록시를 믿고 문을 넓혔네,
Vercel 길목도 살짝 열어,
테스트 한 편은 하늘로 훌쩍,
당근 한 입 축하해요 🥕✨


Note

🎁 Summarized by CodeRabbit Free

Your organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login.

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

Copy link
Collaborator

@ramong26 ramong26 left a comment

Choose a reason for hiding this comment

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

배포오류가 이거군요.. 수고하셨습니다!

@Parkchanyoung0710 Parkchanyoung0710 merged commit ddf8035 into develop Feb 5, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants