Skip to content

Commit

Permalink
enhancement: build backend server with checksum, trigger CI/CD only f…
Browse files Browse the repository at this point in the history
…or the backend
  • Loading branch information
Songmin17 committed Nov 25, 2023
1 parent c67a43b commit 3e5048c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/docker_build_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ on:
branches:
- main
- dev

- feat/ML_server
paths:
- 'backend/**'

jobs:
build:
Expand Down
6 changes: 3 additions & 3 deletions backend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ WORKDIR /app
COPY requirements.txt requirements.txt
RUN pip install --no-cache-dir -r requirements.txt

# Generate and store the checksum
RUN find /app/ -type f -exec sha256sum {} + > app_checksum.txt

COPY . .

# Generate and store the checksum
RUN find /app/ -type f -print0 | sort -z | xargs -0 sha256sum > app_checksum.txt

CMD ["gunicorn", "haengsha.wsgi:application", "--bind", "0.0.0.0:8000"]

0 comments on commit 3e5048c

Please sign in to comment.