Add CACHEBUST build arg to force Docker image rebuilds

Docker's build cache was preventing Portainer from picking up
code changes. Adding a CACHEBUST ARG before COPY invalidates
all subsequent layers when the value changes.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Dorian
2026-02-13 18:05:40 +00:00
parent 330345c1ac
commit bb281b488b
4 changed files with 14 additions and 0 deletions

View File

@@ -20,6 +20,7 @@ services:
context: .
dockerfile: Dockerfile
args:
CACHEBUST: "2"
VITE_USE_MOCK_DATA: "false"
VITE_CONTENT_ORIGIN: ${FRONTEND_URL}
VITE_INDEEHUB_API_URL: /api
@@ -45,6 +46,8 @@ services:
build:
context: ./backend
dockerfile: Dockerfile
args:
CACHEBUST: "2"
restart: unless-stopped
environment:
# ── Core ─────────────────────────────────────────────
@@ -175,6 +178,8 @@ services:
build:
context: ./backend
dockerfile: Dockerfile.ffmpeg
args:
CACHEBUST: "2"
restart: unless-stopped
environment:
ENVIRONMENT: production