-
Notifications
You must be signed in to change notification settings - Fork 177
/
Dockerfile.dev
39 lines (29 loc) · 1007 Bytes
/
Dockerfile.dev
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
29
30
31
32
33
34
35
36
37
38
39
FROM ghcr.io/astral-sh/uv:0.4.20-python3.12-bookworm-slim
# Define the environment variables
ENV UV_SYSTEM_PYTHON=1
ENV HOST=0.0.0.0
ENV PORT=8000
# Expose the application port
EXPOSE $PORT
# Install xmlsec1
RUN apt-get update && apt-get install -y xmlsec1
# Set the working directory inside the container
WORKDIR /app
# Copy the application files into the container
COPY ./tracecat /app/tracecat
COPY ./registry /app/registry
COPY ./pyproject.toml /app/pyproject.toml
COPY ./README.md /app/README.md
COPY ./LICENSE /app/LICENSE
COPY ./alembic.ini /app/alembic.ini
COPY ./alembic /app/alembic
COPY scripts/entrypoint.sh /app/entrypoint.sh
RUN chmod +x /app/entrypoint.sh
# Install package and registry in editable mode
RUN uv pip install -e .
RUN uv pip install -e ./registry
# Install git
RUN apt-get update && apt-get install -y git
ENTRYPOINT ["/app/entrypoint.sh"]
# Command to run the application
CMD ["sh", "-c", "python3 -m uvicorn tracecat.api.app:app --host $HOST --port $PORT --reload"]