reset dockr file changes
This commit is contained in:
parent
e59091b8c7
commit
30fd125d48
18
Dockerfile
18
Dockerfile
@ -1,10 +1,5 @@
|
|||||||
# use older node version for build since arm/v8 threw error when node 20 was used
|
# specify node.js image
|
||||||
FROM node:18.19.1-alpine AS build_image
|
FROM node:22-alpine
|
||||||
|
|
||||||
# install additional tools needed if on arm64 / armv7
|
|
||||||
RUN apk add --update python3 make g++\
|
|
||||||
&& rm -rf /var/cache/apk/*
|
|
||||||
|
|
||||||
|
|
||||||
# use production node environment by default
|
# use production node environment by default
|
||||||
ENV NODE_ENV=production
|
ENV NODE_ENV=production
|
||||||
@ -23,15 +18,6 @@ RUN mkdir -p /var/lib/kutt
|
|||||||
# copy the rest of source files into the image
|
# copy the rest of source files into the image
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
# switch back to node 22 for running the app
|
|
||||||
FROM node:22-alpine
|
|
||||||
|
|
||||||
# set working directory.
|
|
||||||
WORKDIR /kutt
|
|
||||||
|
|
||||||
# copy built application from build phase
|
|
||||||
COPY --from=build_image /kutt ./
|
|
||||||
|
|
||||||
# expose the port that the app listens on
|
# expose the port that the app listens on
|
||||||
EXPOSE 3000
|
EXPOSE 3000
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user