-
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.
Create backend app with expressjs api
- Loading branch information
1 parent
7ce24de
commit 8322f17
Showing
9 changed files
with
2,099 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 |
---|---|---|
|
@@ -6,3 +6,4 @@ node_modules | |
# CDK asset staging directory | ||
.cdk.staging | ||
cdk.out | ||
.env |
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
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,2 @@ | ||
node_modules | ||
.env |
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,21 @@ | ||
# Use node.js image as base | ||
FROM node:latest | ||
|
||
# Set working directory inside the container | ||
WORKDIR /app | ||
|
||
# Copy package.json to the working directory | ||
COPY package.json . | ||
|
||
# Install dependencies | ||
RUN npm install | ||
|
||
# Copy everything | ||
COPY . . | ||
|
||
# Expose the port specified in the .env file | ||
ENV PORT=${PORT} | ||
EXPOSE $PORT | ||
|
||
# Command to run the application | ||
CMD ["npm", "start"] |
Oops, something went wrong.