add Dockerfile
parent
eeb8f411ac
commit
8ae5e9d7b8
|
|
@ -0,0 +1,11 @@
|
|||
node_modules
|
||||
dist
|
||||
test
|
||||
.devcontainer
|
||||
*.log
|
||||
.git
|
||||
*.md
|
||||
Dockerfile
|
||||
.dockerignore
|
||||
.gitignore
|
||||
.prettier*
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
FROM node:23 as builder
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY package*.json ./
|
||||
|
||||
RUN npm install
|
||||
|
||||
COPY . .
|
||||
|
||||
RUN npm run build
|
||||
|
||||
FROM node:23-slim
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY package*.json ./
|
||||
|
||||
RUN npm install --only=production
|
||||
|
||||
COPY --from=builder /app/dist ./dist
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
CMD ["npm", "run", "start:prod"]
|
||||
Loading…
Reference in New Issue