Adds Dockerbuild file
This commit is contained in:
25
Dockerfile
Normal file
25
Dockerfile
Normal file
@@ -0,0 +1,25 @@
|
||||
FROM node:18-alpine as build
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY package*.json .
|
||||
|
||||
RUN npm ci
|
||||
|
||||
COPY . .
|
||||
|
||||
RUN npm run build
|
||||
|
||||
FROM node:18-alpine
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY package*.json .
|
||||
|
||||
RUN npm ci --omit dev
|
||||
|
||||
COPY --from=build /app/build /app/build/
|
||||
|
||||
ENV NODE_ENV="production"
|
||||
|
||||
ENTRYPOINT [ "node", "-r","dotenv/config", "build"]
|
||||
Reference in New Issue
Block a user