-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7 from fossnsbm/main
feat: Dockerfile and docker scripts
- Loading branch information
Showing
3 changed files
with
20 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 @@ | ||
node_modules |
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,6 @@ | ||
FROM node:lts-alpine3.19 | ||
WORKDIR /app | ||
COPY . ./ | ||
RUN yarn | ||
EXPOSE 3000 | ||
CMD yarn dev |
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,13 @@ | ||
echo "Welcome to the Docker Command Line Interface" | ||
echo "-----------------------------------------" | ||
|
||
if [ "$1" == "build" ]; then | ||
docker build -f Dockerfile -t techie-sleuths-frontend . | ||
elif [ "$1" == "run" ]; then | ||
docker run -it -p 3000:3000 techie-sleuths-frontend | ||
elif [ "$1" == "help" ]; then | ||
echo "build: builds the docker image" | ||
echo "run: runs the docker image" | ||
else | ||
echo "Please enter a valid command" | ||
fi |