Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Frontend/dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ RUN npm run build
FROM nginx:alpine
# Vite build 결과(dist)를 nginx 정적 경로로 복사
COPY --from=build /app/dist /usr/share/nginx/html
COPY ./nginx/default.conf /etc/nginx/conf.d/default.conf

# SPA 라우팅 대응(선택): 아래 nginx 설정을 쓰려면 주석 해제
# COPY nginx.conf /etc/nginx/conf.d/default.conf
Expand Down
19 changes: 19 additions & 0 deletions Frontend/nginx/default.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
server {
listen 80;
server_name _;

root /usr/share/nginx/html;
index index.html;

# 정적 파일(assets)은 그대로 제공
location /assets/ {
try_files $uri =404;
expires 7d;
add_header Cache-Control "public, max-age=604800, immutable";
}

# SPA 라우팅: 파일 없으면 index.html로
location / {
try_files $uri $uri/ /index.html;
}
}
2 changes: 1 addition & 1 deletion Frontend/src/pages/MyPage/MyPageLoggedOut.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const MyPageLoggedOut = () => {

const handleGithubLogin = () => {
// OAuth 시작 url
window.location.href = "//"
window.location.href = "http://solvemeup.com/oauth2/authorization/github"
}


Expand Down