What's wrong with my n8n Dockerfile?

Docker version 29.5.3, build d1c06ef, trying to use this Dockerfile

FROM n8nio/n8n:latest-debian

USER root

RUN apt-get update && apt-get install -y 
chromium 
chromium-driver 
fonts-liberation 
libasound2 
libatk-bridge2.0-0 
libatk1.0-0 
libcups2 
libdbus-1-3 
libdrm2 
libgbm1 
libgtk-3-0 
libnspr4 
libnss3 
libxcomposite1 
libxdamage1 
libxfixes3 
libxkbcommon0 
libxrandr2 
libpangocairo-1.0-0 
libxss1 
libx11-xcb1 
libxcursor1 
libxi6 
libxtst6 
libxrender1 
libxext6 
nss 
freetype 
harfbuzz 
ca-certificates 
ttf-freefont 
nodejs 
npm 
wget 
xdg-utils 
--no-install-recommends 
&& apt-get clean 
&& rm -rf /var/lib/apt/lists/*

ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium

ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium-browser

ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/google-chrome-stable

ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true

ENV CHROME_VERSION=148.0.7778.97
ENV PUPPETEER_CHROMIUM_REVISION=148.0.7778.97
ENV PUPPETEER_PRODUCT=chrome

wget - q "http://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_148.0.7778.96-1_amd64.deb"

#RUN wget -q "https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${CHROME_VERSION}-1_amd64.deb" \

&& dpkg -i google-chrome-stable_${CHROME_VERSION}-1_amd64.deb || apt-get install -f -y \

&& rm google-chrome-stable_${CHROME_VERSION}-1_amd64.deb

RUN google-chrome-stable --version

RUN mkdir -p /home/node/.cache/puppeteer && 
chown -R node:node /home/node/.cache

Install Puppeteer community node (if needed)

RUN cd /home/node/.n8n && 
npm install -g puppeteer --unsafe-perm && 
npm install n8n-nodes-puppeteer && 
npx puppeteer browsers install chrome

USER node

RUN google-chrome-stable --version

My docker-n8n-3.yml

services:
n8n:
build:
context: .
dockerfile: Dockerfile-3
image: n8nio/n8n:latest
container_name: n8n-main
environment:
- N8N_SECURE_COOKIE=false
- N8N_HOST=localhost
- N8N_PORT=5678
- WEBHOOK_URL=http://localhost:5678
# Task Runner configuration
- N8N_RUNNERS_ENABLED=true
- N8N_RUNNERS_MODE=external
- N8N_RUNNERS_BROKER_LISTEN_ADDRESS=0.0.0.0
- N8N_RUNNERS_AUTH_TOKEN=your-secret-token-here-change-me
- N8N_NATIVE_PYTHON_RUNNER=true
- PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium-browser
ports:
- "5678:5678"
volumes:
- n8n_data:/home/node/.n8n
restart: unless-stopped
depends_on:
- task-runners

task-runners:
image: n8nio/runners:latest
container_name: n8n-runners
environment:
- N8N_RUNNERS_AUTH_TOKEN=your-secret-token-here-change-me
- N8N_RUNNERS_TASK_BROKER_URI=http://n8n-main:5679
- N8N_RUNNERS_AUTO_SHUTDOWN_TIMEOUT=15
restart: unless-stopped

volumes:
n8n_data:

Then I run this command

docker compose -f docker-n8n-3.yml build --no-cache

and get this failure:

C:\prj\n8n>docker compose -f docker-n8n-3.yml build --no-cache
#1 [internal] load local bake definitions
#1 reading from stdin 492B done
#1 DONE 0.0s

#2 [internal] load build definition from Dockerfile-3
#2 transferring dockerfile: 2.02kB 0.0s done
#2 DONE 0.0s

#3 [internal] load metadata for docker.io/n8nio/n8n:latest-debian
#3 DONE 0.7s

#4 [internal] load .dockerignore
#4 transferring context: 2B done
#4 DONE 0.0s

#5 [1/6] FROM docker.io/n8nio/n8n:latest-debian@sha256:aae7b1b6faab7c400fa9141f0211ab8c0e27d34409c29bf096918a9729167677
#5 resolve docker.io/n8nio/n8n:latest-debian@sha256:aae7b1b6faab7c400fa9141f0211ab8c0e27d34409c29bf096918a9729167677 0.1s done
#5 DONE 0.1s

#5 [1/6] FROM docker.io/n8nio/n8n:latest-debian@sha256:aae7b1b6faab7c400fa9141f0211ab8c0e27d34409c29bf096918a9729167677
#5 CACHED

#6 [2/6] RUN apt-get update && apt-get install -y     chromium     chromium-driver     fonts-liberation     libasound2     libatk-bridge2.0-0     libatk1.0-0     libcups2     libdbus-1-3     libdrm2     libgbm1     libgtk-3-0     libnspr4     libnss3     libxcomposite1     libxdamage1     libxfixes3     libxkbcommon0     libxrandr2     libpangocairo-1.0-0     libxss1     libx11-xcb1     libxcursor1     libxi6     libxtst6     libxrender1     libxext6     nss     freetype     harfbuzz     ca-certificates     ttf-freefont     nodejs     npm     wget     xdg-utils     --no-install-recommends     && apt-get clean     && rm -rf /var/lib/apt/lists/*
#6 0.342 Ign:1 http://deb.debian.org/debian buster InRelease
#6 0.355 Ign:2 http://deb.debian.org/debian-security buster/updates InRelease
#6 0.369 Ign:3 http://deb.debian.org/debian buster-updates InRelease
#6 0.382 Err:4 http://deb.debian.org/debian buster Release
#6 0.382   404  Not Found [IP: 151.101.66.132 80]
#6 0.394 Err:5 http://deb.debian.org/debian-security buster/updates Release
#6 0.394   404  Not Found [IP: 151.101.66.132 80]
#6 0.409 Err:6 http://deb.debian.org/debian buster-updates Release
#6 0.409   404  Not Found [IP: 151.101.66.132 80]
#6 0.425 Reading package lists...
#6 1.098 E: The repository 'http://deb.debian.org/debian buster Release' no longer has a Release file.
#6 1.098 E: The repository 'http://deb.debian.org/debian-security buster/updates Release' no longer has a Release file.
#6 1.098 E: The repository 'http://deb.debian.org/debian buster-updates Release' no longer has a Release file.
#6 ERROR: process "/bin/sh -c apt-get update && apt-get install -y     chromium     chromium-driver     fonts-liberation     libasound2     libatk-bridge2.0-0     libatk1.0-0     libcups2     libdbus-1-3     libdrm2     libgbm1     libgtk-3-0     libnspr4     libnss3     libxcomposite1     libxdamage1     libxfixes3     libxkbcommon0     libxrandr2     libpangocairo-1.0-0     libxss1     libx11-xcb1     libxcursor1     libxi6     libxtst6     libxrender1     libxext6     nss     freetype     harfbuzz     ca-certificates     ttf-freefont     nodejs     npm     wget     xdg-utils     --no-install-recommends     && apt-get clean     && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100

[2/6] RUN apt-get update && apt-get install -y     chromium     chromium-driver     fonts-liberation     libasound2     libatk-bridge2.0-0     libatk1.0-0     libcups2     libdbus-1-3     libdrm2     libgbm1     libgtk-3-0     libnspr4     libnss3     libxcomposite1     libxdamage1     libxfixes3     libxkbcommon0     libxrandr2     libpangocairo-1.0-0     libxss1     libx11-xcb1     libxcursor1     libxi6     libxtst6     libxrender1     libxext6     nss     freetype     harfbuzz     ca-certificates     ttf-freefont     nodejs     npm     wget     xdg-utils     --no-install-recommends     && apt-get clean     && rm -rf /var/lib/apt/lists/*:
0.342 Ign:1 http://deb.debian.org/debian buster InRelease

1.098 E: The repository 'http://deb.debian.org/debian buster Release' no longer has a Release file.
1.098 E: The repository 'http://deb.debian.org/debian-security buster/updates Release' no longer has a Release file.
1.098 E: The repository 'http://deb.debian.org/debian buster-updates Release' no longer has a Release file.

[+] build 0/1

Image n8nio/n8n:latest Building                                                                                                                                                                                                       2.7s
Dockerfile-3:5




4 |

5 | >>> RUN apt-get update && apt-get install -y \

6 | >>>     chromium \

7 | >>>     chromium-driver \

8 | >>>     fonts-liberation \

9 | >>>     libasound2 \

10 | >>>     libatk-bridge2.0-0 \

11 | >>>     libatk1.0-0 \

12 | >>>     libcups2 \

13 | >>>     libdbus-1-3 \

14 | >>>     libdrm2 \

15 | >>>     libgbm1 \

16 | >>>     libgtk-3-0 \

17 | >>>     libnspr4 \

18 | >>>     libnss3 \

19 | >>>     libxcomposite1 \

20 | >>>     libxdamage1 \

21 | >>>     libxfixes3 \

22 | >>>     libxkbcommon0 \

23 | >>>     libxrandr2 \

24 | >>>     libpangocairo-1.0-0 \

25 | >>>     libxss1 \

26 | >>>     libx11-xcb1 \

27 | >>>     libxcursor1 \

28 | >>>     libxi6 \

29 | >>>     libxtst6 \

30 | >>>     libxrender1 \

31 | >>>     libxext6 \

32 | >>>     nss \

33 | >>>     freetype \

34 | >>>     harfbuzz \

35 | >>>     ca-certificates \

36 | >>>     ttf-freefont \

37 | >>>     nodejs \

38 | >>>     npm \

39 | >>>     wget \

40 | >>>     xdg-utils \

41 | >>>     --no-install-recommends \

42 | >>>     && apt-get clean \

43 | >>>     && rm -rf /var/lib/apt/lists/*

44 |




failed to solve: process "/bin/sh -c apt-get update && apt-get install -y     chromium     chromium-driver     fonts-liberation     libasound2     libatk-bridge2.0-0     libatk1.0-0     libcups2     libdbus-1-3     libdrm2     libgbm1     libgtk-3-0     libnspr4     libnss3     libxcomposite1     libxdamage1     libxfixes3     libxkbcommon0     libxrandr2     libpangocairo-1.0-0     libxss1     libx11-xcb1     libxcursor1     libxi6     libxtst6     libxrender1     libxext6     nss     freetype     harfbuzz     ca-certificates     ttf-freefont     nodejs     npm     wget     xdg-utils     --no-install-recommends     && apt-get clean     && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100

View build details: docker-desktop://dashboard/build/default/default/wd8k9z8wye7otb1zxd89o07ed

What's next:
Debug this Compose error with Gordon → docker ai "help me fix this compose error"

C:\prj\n8n>

Could someone tell me what’s wrong with my files here? And how to have them fixed?

Your shared files are invalid as the indentation is wrong and in the Dockerfile, the escape character at the end of lines is missing, but the error message indicates it was correct before you shared it and the problem is with a missing package probably since the apt-get install command is failing.

update:

This shows the repositories are not available. “buster” is an old Debian version and I think the repositories are moved to an archive repo, except securty which will not work at all for outdated versons. I would search for what repo can be sued for Debian 10 in 2026 or base the image on a newer version.

It seems the tag latest-debian hasn’t been updated for over 3 years (link). Use a different image tag.

You probably need to extend a runner image, check the n8n compose repo.