From bae71f110a93ca96abd74e84296f7b3ef8287921 Mon Sep 17 00:00:00 2001 From: "Tashi D. Gyeltshen" Date: Mon, 13 May 2024 10:58:06 -0400 Subject: [PATCH] Add `Dockerfile`. --- Dockerfile | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..7155841 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,20 @@ +# Use Node 16 alpine as parent image +FROM node:22-alpine + +# Change the working directory on the Docker image to /app +WORKDIR /app + +# Copy package.json and package-lock.json to the /app directory +COPY package.json package-lock.json ./ + +# Install dependencies +RUN npm install + +# Copy the rest of project files into this image +COPY . . + +# Expose application port +EXPOSE 3000 + +# Start the application +CMD npm run prod