Skip to content

Commit f4310cf

Browse files
authored
chore: 도커 설정 파일 추가 (#39)
* chore: 도커 설정 파일 추가 * chore: nginx.conf 설정 추가 - close #38 * chore: /api 프록시 경로 변경
1 parent 1dc8729 commit f4310cf

File tree

2 files changed

+23
-0
lines changed

2 files changed

+23
-0
lines changed

Dockerfile

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
FROM node:22 AS builder
2+
WORKDIR /app
3+
COPY package*.json ./
4+
RUN npm install
5+
COPY . .
6+
RUN npm run build
7+
8+
FROM nginx:alpine
9+
COPY --from=builder /app/dist /usr/share/nginx/html
10+
COPY nginx.conf /etc/nginx/conf.d/default.conf
11+
EXPOSE 8080
12+
CMD ["nginx", "-g", "daemon off;"]

nginx.conf

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
server {
2+
listen 8080;
3+
root /usr/share/nginx/html;
4+
index index.html;
5+
location / {
6+
try_files $uri /index.html;
7+
}
8+
location /api/ {
9+
proxy_pass http://command-tracker-staging.ap-northeast-2.elasticbeanstalk.com;
10+
}
11+
}

0 commit comments

Comments
 (0)