-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
32 lines (25 loc) · 860 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# To build the container:
# docker build . -t awoisoak/photo-shop
# To run it directly from docker hub:
# docker run -p 9000:9000 -ti awoisoak/photo-shop
# Force platform to avoid issues with Apple silicon processors
FROM --platform=linux/amd64 ubuntu
# Install dependencies
RUN apt update
RUN apt install python3 -y
RUN apt install python3-pip -y
RUN apt install curl -y
RUN apt install mysql-client -y
RUN apt install libmysqlclient-dev -y
RUN apt install dnsutils -y
# Copy source code to working directory
COPY . /opt/photo_shop
# Set the working directory
WORKDIR /opt/photo_shop
# Install the dependencies and packages in the requirements file
RUN pip install -r requirements.txt
# Flask will expose port 9000 for the website
EXPOSE 9000
# Run Flask webserver. -u flag to force unbuffered output
ENTRYPOINT [ "python3", "-u" ]
CMD ["app.py" ]