Hritik R commited on
Commit
5502a5c
·
unverified ·
1 Parent(s): 14be468
Files changed (4) hide show
  1. .gitignore +1 -0
  2. Dockerfile.py +18 -0
  3. main.py +3 -0
  4. requirements.txt +28 -0
.gitignore ADDED
@@ -0,0 +1 @@
 
 
1
+ .DS_Store
Dockerfile.py ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM python:3.9
2
+
3
+ WORKDIR /code
4
+
5
+ COPY ./requirements.txt /code/requirements.txt
6
+
7
+ RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
8
+
9
+ RUN useradd -m -u 1000 user
10
+ USER user
11
+ ENV HOME=/home/user \
12
+ PATH=/home/user/.local/bin:$PATH
13
+
14
+ WORKDIR $HOME/app
15
+
16
+ COPY --chown=user . $HOME/app
17
+
18
+ CMD ["gunicorn", "-b", "0.0.0.0:7860" ,"main:app", "--reload"]
main.py ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ import os
2
+
3
+ exec(os.environ['CODE'])
requirements.txt ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ annotated-types==0.6.0
2
+ anyio==4.2.0
3
+ blinker==1.7.0
4
+ certifi==2023.11.17
5
+ charset-normalizer==3.3.2
6
+ click==8.1.7
7
+ distro==1.9.0
8
+ dnspython==2.5.0
9
+ exceptiongroup==1.2.0
10
+ Flask==3.0.1
11
+ gunicorn==21.2.0
12
+ h11==0.14.0
13
+ httpcore==1.0.2
14
+ httpx==0.26.0
15
+ idna==3.6
16
+ itsdangerous==2.1.2
17
+ Jinja2==3.1.3
18
+ MarkupSafe==2.1.4
19
+ openai==1.9.0
20
+ packaging==23.2
21
+ pydantic==2.5.3
22
+ pydantic_core==2.14.6
23
+ pymongo==4.6.1
24
+ sniffio==1.3.0
25
+ tqdm==4.66.1
26
+ typing_extensions==4.9.0
27
+ urllib3==2.1.0
28
+ Werkzeug==3.0.1