d7988509cf
## 1.7.0 / 2026-05-12 ### New * Add toast notification system with HTMX middleware integration * Add component system (Cotton-based): button, modal, table_row, search_field, gamelink * Add needs_price_update field to Purchase model for reliable price change detection * Add confirmation dialog before deleting a game * Add game status information documentation (STATUSES.md) * Allow directly updating device in session list via inline selector * Migrate from Poetry to uv for Python dependency management * Scope URLs to the games namespace * Start session template shared between add and edit views ### Improved * Major style overhaul: CSS variables, improved dark mode, Flowbite 4.x upgrade * Improve game status evaluation and add abandon prompt on refund * Robustify Docker container and fix default database location * Make component rendering deterministic for improved caching * Component caching: deterministic randomid generation * Component test suite with 1000+ lines of tests * Make tests more robust with django-pytest * Update NameWithIcon component: testable, fixed platform extraction bug * Pin Caddy version and improve make dev-prod * Add .env.example documenting environment variables * Unify A() component with explicit url_name vs href parameters ### Fixed * Fix refund confirmation not working * Fix stats view missing first and last game values * Fix A() component silent fallback on URL typos * Fix secondary submit buttons not working * Fix button not passing attributes * Fix default mutable arguments in component functions * Fix extra submit button when adding purchase * Fix pointer cursor on search field button ### Removed * Remove GraphQL API ### Dependencies * Update django-ninja to 1.6.2
56 lines
1.7 KiB
Docker
56 lines
1.7 KiB
Docker
FROM ghcr.io/astral-sh/uv:python3.14-bookworm-slim AS builder
|
|
|
|
ENV UV_LINK_MODE=copy \
|
|
UV_COMPILE_BYTECODE=1 \
|
|
PYTHONUNBUFFERED=1
|
|
|
|
WORKDIR /home/timetracker/app
|
|
|
|
RUN --mount=type=cache,target=/root/.cache/uv \
|
|
--mount=type=bind,source=uv.lock,target=uv.lock \
|
|
--mount=type=bind,source=pyproject.toml,target=pyproject.toml \
|
|
uv sync --frozen --no-install-project --no-dev
|
|
|
|
COPY . .
|
|
RUN --mount=type=cache,target=/root/.cache/uv \
|
|
uv sync --frozen --no-dev
|
|
|
|
|
|
FROM python:3.14-slim-bookworm
|
|
|
|
ENV PROD=1 \
|
|
PYTHONUNBUFFERED=1 \
|
|
PATH="/home/timetracker/app/.venv/bin:$PATH"
|
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
curl \
|
|
ca-certificates \
|
|
libcap2-bin \
|
|
supervisor \
|
|
&& rm -rf /var/lib/apt/lists/* \
|
|
&& useradd -m --uid 1000 timetracker \
|
|
&& mkdir -p /var/log/supervisor /etc/supervisor/conf.d /home/timetracker/data \
|
|
&& chown timetracker:timetracker /var/log/supervisor /home/timetracker/data
|
|
|
|
ARG CADDY_VERSION=2.9.1
|
|
RUN curl -sL "https://github.com/caddyserver/caddy/releases/download/v${CADDY_VERSION}/caddy_${CADDY_VERSION}_linux_amd64.tar.gz" \
|
|
-o /tmp/caddy.tar.gz && \
|
|
tar -xzf /tmp/caddy.tar.gz -C /tmp && \
|
|
mv /tmp/caddy /usr/local/bin/caddy && \
|
|
rm /tmp/caddy.tar.gz && \
|
|
chmod +x /usr/local/bin/caddy
|
|
|
|
WORKDIR /home/timetracker/app
|
|
|
|
COPY --from=builder --chown=timetracker:timetracker /home/timetracker/app /home/timetracker/app
|
|
|
|
COPY --chown=timetracker:timetracker Caddyfile /etc/caddy/Caddyfile
|
|
COPY --chown=timetracker:timetracker supervisor.conf /etc/supervisor/conf.d/supervisor.conf
|
|
COPY --chown=timetracker:timetracker entrypoint.sh /
|
|
RUN chmod +x /entrypoint.sh
|
|
|
|
ENV VERSION_NUMBER=1.7.0
|
|
|
|
EXPOSE 8000
|
|
ENTRYPOINT ["/entrypoint.sh"]
|