Skip to content

🐸 Rybbit - open-source and privacy-friendly alternative to Google Analytics that is 10x more intuitive.

Update Dockerfiles to pin Node.js base images to specific patch versions and configure Dependabot for daily updates on Docker dependencies. (#1319)

Goldflag5b8a888208c3
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
index d1f0d0851..bf0ea9b37 100644
--- a/.github/dependabot.yml
+++ b/.github/dependabot.yml
@@ -4,3 +4,11 @@ updates:
directory: "/"
schedule:
interval: "daily"
+ # Base images are pinned to exact Node patch releases, so let Dependabot raise
+ # them when Node ships a security release instead of relying on a floating tag.
+ - package-ecosystem: "docker"
+ directories:
+ - "/server"
+ - "/client"
+ schedule:
+ interval: "daily"
diff --git a/client/Dockerfile b/client/Dockerfile
index ae3aa46ae..a7f37cd38 100644
--- a/client/Dockerfile
+++ b/client/Dockerfile
@@ -1,6 +1,6 @@
# syntax=docker/dockerfile:1
-FROM node:24-alpine AS base
+FROM node:24.22.1-alpine AS base
ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
RUN corepack enable
@@ -42,7 +42,7 @@ ENV NEXT_PUBLIC_LITE_DASHBOARD=${NEXT_PUBLIC_LITE_DASHBOARD}
RUN pnpm run build:client
# Production image, copy all the files and run next
-FROM node:24-alpine AS runner
+FROM node:24.22.1-alpine AS runner
WORKDIR /app
ENV NODE_ENV=production
diff --git a/server/Dockerfile b/server/Dockerfile
index 03cdab783..bcd44e194 100644
--- a/server/Dockerfile
+++ b/server/Dockerfile
@@ -1,6 +1,6 @@
# syntax=docker/dockerfile:1
-FROM node:24-alpine AS deps
+FROM node:24.22.1-alpine AS deps
ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
# The runtime image supplies Chromium through apk.
@@ -24,7 +24,7 @@ RUN --mount=type=cache,id=pnpm,target=/pnpm/store \
pnpm --filter rybbit-backend deploy --legacy --prod --store-dir /pnpm/store /prod/server
# Runtime image
-FROM node:24-alpine
+FROM node:24.22.1-alpine
WORKDIR /app