From 7da037ac1b882fe15c5dac0f596f4d5163abaef8 Mon Sep 17 00:00:00 2001 From: IshayuR Date: Wed, 30 Oct 2024 23:02:20 -0400 Subject: [PATCH] change location of dockerfile and add requirements.txt --- Backend/dockerfile | 30 ++++++++++++++++++++++++++++++ Backend/requirements.txt | 3 +++ 2 files changed, 33 insertions(+) create mode 100644 Backend/dockerfile create mode 100644 Backend/requirements.txt diff --git a/Backend/dockerfile b/Backend/dockerfile new file mode 100644 index 0000000..b329730 --- /dev/null +++ b/Backend/dockerfile @@ -0,0 +1,30 @@ +# For more information, please refer to https://aka.ms/vscode-docker-python +#just so yk this dockerfile is the template docker gave me lol +# + +FROM ubuntu:latest +FROM python:3.8-slim-buster +#install pip & python3 +RUN apt-get update && apt-get install -y python3 python3-pip +# Keeps Python from generating .pyc files in the container +ENV PYTHONDONTWRITEBYTECODE=1 + +# Turns off buffering for easier container logging +ENV PYTHONUNBUFFERED=1 + +# Install pip requirements +COPY requirements.txt . +#just use python3 +RUN python3 -m pip install -r requirements.txt + +COPY main.py /main.py +ENV PORT=5000 +EXPOSE 5000 + +# Creates a non-root user with an explicit UID and adds permission to access the /app folder +# For more info, please refer to https://aka.ms/vscode-docker-python-configure-containers +#RUN adduser -u 5678 --disabled-password --gecos "" appuser && chown -R appuser /app +#USER appuser + +# During debugging, this entry point will be overridden. For more information, please refer to https://aka.ms/vscode-docker-python-debug +CMD ["python3", "main.py"] \ No newline at end of file diff --git a/Backend/requirements.txt b/Backend/requirements.txt new file mode 100644 index 0000000..bd5556c --- /dev/null +++ b/Backend/requirements.txt @@ -0,0 +1,3 @@ +Flask==2.0.3 +requests==2.26.0 +pandas==1.3.4