-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
26 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Use the official Node.js image. | ||
# The version of Node.js can be adjusted as necessary. | ||
FROM node:14 | ||
|
||
# Create and change to the app directory. | ||
WORKDIR /usr/src/app | ||
|
||
# Copy package.json and package-lock.json. | ||
COPY package*.json ./ | ||
|
||
# Install dependencies. | ||
RUN npm install | ||
|
||
# Copy the rest of the application code. | ||
COPY . . | ||
|
||
# Expose the port the app runs on, if needed (for example, 8080). | ||
# EXPOSE 8080 | ||
|
||
# Define environment variable for the path to .env file. | ||
ENV NODE_ENV=production | ||
|
||
# Command to run the application. | ||
CMD ["node", "index.js"] | ||
|
||
# Note: Replace 'index.js' with the actual entry point of your application. |