sp500_vs_btp / Dockerfile
pnovelli's picture
Updated dockerfile
424e006
raw
history blame contribute delete
678 Bytes
FROM python:3.12
COPY --from=ghcr.io/astral-sh/uv:0.4.20 /uv /bin/uv
RUN useradd -m -u 1000 user
ENV PATH="/home/user/.local/bin:$PATH"
ENV UV_SYSTEM_PYTHON=1
WORKDIR /app
# 1. Copy all application files into the container.
# The .dockerignore file will prevent unnecessary files from being copied.
COPY . .
# 2. Install Python dependencies.
RUN uv sync
# 3. Create marimo's directory and set correct permissions for the app folder.
RUN mkdir -p /app/__marimo__ && \
chown -R user:user /app && \
chmod -R 755 /app
USER user
# 4. Execute the marimo application.
CMD ["uv", "run", "marimo", "run", "main.py", "--include-code", "--host", "0.0.0.0", "--port", "7860"]