-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
127 feature docker compose only deployment (#157)
* Add tags to ignore. (commit message: "Ignore tags") * 🎉 feat(frontend): add Dockerfile and docker-compose.yml for frontend * Refactor frontend Dockerfile
- Loading branch information
1 parent
c89575f
commit 12a65eb
Showing
4 changed files
with
73 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 |
---|---|---|
|
@@ -28,3 +28,4 @@ delete.bat | |
.Rhistory | ||
model/build/Mask* | ||
model/build/taco* | ||
tags |
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,34 @@ | ||
# Include any files or directories that you don't want to be copied to your | ||
# container here (e.g., local build artifacts, temporary files, etc.). | ||
# | ||
# For more help, visit the .dockerignore file reference guide at | ||
# https://docs.docker.com/engine/reference/builder/#dockerignore-file | ||
|
||
**/.DS_Store | ||
**/__pycache__ | ||
**/.venv | ||
**/.classpath | ||
**/.dockerignore | ||
**/.env | ||
**/.git | ||
**/.gitignore | ||
**/.project | ||
**/.settings | ||
**/.toolstarget | ||
**/.vs | ||
**/.vscode | ||
**/*.*proj.user | ||
**/*.dbmdl | ||
**/*.jfm | ||
**/bin | ||
**/charts | ||
**/docker-compose* | ||
**/compose* | ||
**/Dockerfile* | ||
**/node_modules | ||
**/npm-debug.log | ||
**/obj | ||
**/secrets.dev.yaml | ||
**/values.dev.yaml | ||
LICENSE | ||
README.md |
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,32 @@ | ||
# Dockerfile for trash-ai frontend | ||
|
||
# Stage 1: Build the project | ||
FROM node:16.12.0 as builder | ||
|
||
# Set the working directory | ||
WORKDIR /app | ||
|
||
# Copy the package.json and yarn.lock files | ||
COPY package.json yarn.lock ./ | ||
|
||
# Install dependencies | ||
RUN yarn install | ||
|
||
# Copy the rest of the project files | ||
COPY . . | ||
|
||
# Build the project | ||
RUN yarn build | ||
|
||
# Stage 2: Serve the built project with Nginx | ||
FROM nginx:1.23.3 | ||
|
||
# Copy the built project from the previous stage | ||
COPY --from=builder /app/dist /usr/share/nginx/html | ||
|
||
# Expose port 80 | ||
EXPOSE 80 | ||
|
||
# Start Nginx | ||
CMD ["nginx", "-g", "daemon off;"] | ||
|
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 @@ | ||
version: '3' | ||
services: | ||
frontend: | ||
build: . | ||
ports: | ||
- "8080:80" |