File size: 1,227 Bytes
1228ed9
 
ecb177b
a8dfddc
1228ed9
a8dfddc
1228ed9
a8dfddc
1228ed9
ecb177b
 
a8dfddc
ecb177b
a8dfddc
0232d80
9fdff39
 
9be6535
 
a4a9857
 
4c22d66
9be6535
 
 
 
192204f
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
FROM bitnami/pytorch

RUN mkdir --mode 777 /app/my_streamlit_app
WORKDIR /app/my_stramlit_app

COPY ./requirements.txt /app/my_streamlit_app/requirements.txt

RUN pip install --no-cache-dir -r /app/my_streamlit_app/requirements.txt

RUN mkdir --mode 777 "/app/my_streamlit_app/.cache/"
RUN mkdir --mode 777 "/app/my_streamlit_app/.cache/huggingface/"
ENV HUGGINGFACE_HUB_CACHE="/app/my_streamlit_app/.cache/huggingface"
RUN mkdir --mode 777 "/app/my_streamlit_app/.cache/transformers/"
ENV TRANSFORMERS_CACHE="/app/my_streamlit_app/.cache/transformers"

ENV TOKENIZERS_PARALLELISM=false

COPY ./download_repo.py /app/my_streamlit_app/download_repo.py
COPY ./available_models.py /app/my_streamlit_app/available_models.py

RUN python /app/my_streamlit_app/download_repo.py

COPY ./app.py /app/my_streamlit_app/app.py
COPY ./hanlde_form_submit.py /app/my_streamlit_app/hanlde_form_submit.py
COPY ./user_instructions_hebrew.md /app/my_streamlit_app/user_instructions_hebrew.md

CMD ["streamlit", "run", "--server.port", "7860", "--server.enableCORS", "false", "--server.enableXsrfProtection", "false", "--browser.gatherUsageStats", "false", "--theme.base", "dark", "--server.maxUploadSize", "1000", "/app/my_streamlit_app/app.py"]