File size: 542 Bytes
639f871
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
fae36f1
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
FROM python:3.10-slim

RUN useradd -m -u 1000 user
USER user

ENV PATH="/home/user/.local/bin:$PATH" \
    PYTHONUNBUFFERED=1

WORKDIR /home/user/app

COPY --chown=user:user requirements.txt /home/user/app/
RUN pip install --no-cache-dir -r requirements.txt

COPY --chown=user:user . /home/user/app/

EXPOSE 7860

# protezioni CORS e XSRF disabilitate per Streamlit
CMD bash -c "python app.py & sleep 3 && streamlit run streamlit_ui.py --server.port 7860 --server.address 0.0.0.0 --server.enableCORS false --server.enableXsrfProtection false"