Upgrade TeslaMate v2.2.0 → v3.0.0 (#279)
All checks were successful
Build Container (Nix) / detect (push) Successful in 2s
Build Container (Nix) / build (teslamate) (push) Successful in 2s
Build Container / detect (push) Successful in 26s
Build Container / build (teslamate) (push) Successful in 4m22s

## Summary
- Upgrade TeslaMate from v2.2.0 to v3.0.0 (first service review)
- Elixir 1.18 → 1.19.5, runtime base bookworm → trixie
- Adds zstd/brotli build deps for new static asset compression
- DB migration (BTREE → BRIN indexes) runs automatically via entrypoint

## Deployment and Testing
- [ ] Trigger container build: `mise run container-build-and-release teslamate`
- [ ] Update kustomization.yaml with new image tag
- [ ] Deploy from branch: `argocd app set teslamate --revision upgrade/teslamate-v3.0.0 && argocd app sync teslamate`
- [ ] Verify TeslaMate UI loads and data is intact
- [ ] Check logs for migration errors
- [ ] After merge: reset ArgoCD to main, update kustomization tag to `[main]` image

Reviewed-on: #279
This commit is contained in:
Erich Blume 2026-03-03 11:56:40 -08:00
commit eb9bc57351
3 changed files with 11 additions and 12 deletions

View file

@ -1,17 +1,17 @@
# TeslaMate - Tesla data logger
# Based on upstream Dockerfile
ARG CONTAINER_APP_VERSION=v2.2.0
ARG CONTAINER_APP_VERSION=v3.0.0
ARG TESLAMATE_VERSION=${CONTAINER_APP_VERSION}
FROM elixir:1.18-otp-26 AS builder
FROM elixir:1.19.5-otp-26 AS builder
ARG TESLAMATE_VERSION
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
RUN apt-get update \
&& apt-get install -y ca-certificates curl gnupg git \
&& apt-get install -y ca-certificates curl gnupg git zstd brotli \
&& mkdir -p /etc/apt/keyrings \
&& curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key \
| gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg \
@ -43,7 +43,7 @@ RUN mix compile
RUN SKIP_LOCALE_DOWNLOAD=true mix release --path /opt/built
# Runtime image
FROM debian:bookworm-slim AS app
FROM debian:trixie-slim AS app
ENV LANG=C.UTF-8 \
SRTM_CACHE=/opt/app/.srtm_cache \
@ -54,7 +54,7 @@ WORKDIR $HOME
RUN apt-get update && apt-get install -y --no-install-recommends \
libodbc2 \
libsctp1 \
libssl3 \
libssl3t64 \
libstdc++6 \
netcat-openbsd \
tini \
@ -65,11 +65,9 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
&& useradd --uid 10000 --system --gid nonroot --home-dir /home/nonroot --shell /sbin/nologin nonroot \
&& chown -R nonroot:nonroot .
COPY entrypoint.sh /
COPY --from=builder /opt/built .
RUN chmod 555 /entrypoint.sh && \
chown -R nonroot:nonroot . && \
mkdir $SRTM_CACHE
COPY --chown=nonroot:nonroot --chmod=555 entrypoint.sh /
COPY --from=builder --chown=nonroot:nonroot /opt/built .
RUN mkdir $SRTM_CACHE
USER nonroot:nonroot