App was crash-looping when the host restarted and Docker brought up the app container before postgres was ready. Added a pg_isready poll loop in entrypoint.sh and installed postgresql-client in the image. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
17 lines
441 B
Docker
17 lines
441 B
Docker
FROM python:3.12-slim
|
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends postgresql-client && rm -rf /var/lib/apt/lists/*
|
|
|
|
WORKDIR /app
|
|
COPY pyproject.toml .
|
|
RUN pip install --no-cache-dir -e ".[mcp]"
|
|
|
|
COPY alembic.ini .
|
|
COPY alembic/ alembic/
|
|
COPY corvid/ corvid/
|
|
COPY entrypoint.sh .
|
|
# templates are bundled inside corvid/ package dir — no extra COPY needed
|
|
RUN chmod +x entrypoint.sh
|
|
|
|
EXPOSE 8080
|
|
CMD ["./entrypoint.sh"]
|