Skip to content

Commit

Permalink
dockerize api
Browse files Browse the repository at this point in the history
  • Loading branch information
bedre7 committed Oct 4, 2024
1 parent 5653cfa commit 8032dfb
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
16 changes: 16 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
FROM python:3.10

# set the working directory
WORKDIR /app

COPY requirements.txt /app/

# install dependencies
RUN pip install -r requirements.txt

COPY . /app/

EXPOSE 5000

# run the application
CMD ["flask", "run", "--host=0.0.0.0"]
10 changes: 10 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
version: "3.8"

services:
web:
build: .
restart: always
ports:
- "5000:5000"
environment:
- FLASK_ENV=development

0 comments on commit 8032dfb

Please sign in to comment.