Skip to content

Commit

Permalink
👷 Init: CI/CD 세팅 (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
yjsmk0902 committed May 17, 2024
1 parent d0a9f3d commit 0a045bf
Showing 1 changed file with 10 additions and 12 deletions.
22 changes: 10 additions & 12 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,18 @@
# Build stage
FROM python:3.9-slim AS build

WORKDIR /app

COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt

COPY . .

# Final stage
# Use the official Python image from the Docker Hub
FROM python:3.9-slim

# 현재 디렉토리의 모든 파일들을 컨테이너의 /app 디렉토리에 복사한다.
COPY . /app

# Set the working directory in the container
WORKDIR /app

COPY --from=build /app /app
# Copy the requirements.txt file into the container
RUN pip install -r requirements.txt


# Make port 5000 available to the world outside this container
EXPOSE 5000

# Command to run the application
CMD ["python", "app.py"]

0 comments on commit 0a045bf

Please sign in to comment.