Hello World doesn't build on Raspberry Pi Zero W

Hi guys. I’m a newby to Balena so I am working through the Getting started with Raspberry Pi zero documentation. I’ve created the fleet and can see my device is on line. When I run the cpommand - balena fleet list I see my fleet and active device.

When I run the command “balena push Dicks-fleet-1” I get the following output:

PS D:\Balena\balena-nodejs-hello-world-master> balena push Dicks-fleet-1

  • Packaging the project source…service.ports.mode is not supported. Removing from the composition
    [Info] Converting line endings CRLF → LF for file: D:\Balena\balena-nodejs-hello-world-master\views\index.html
    [Info] Converting line endings CRLF → LF for file: D:\Balena\balena-nodejs-hello-world-master\views\public\main.css
    [Info] Starting build for dicks-fleet-1, user richard35
    [Info] Dashboard link: balena dashboard
    [Info] Building on a8df1a3
    [Info] No suitable previous release for caching, skipping cache pull
    [balena-hello-world] Step 1/11 : FROM node:22-bookworm-slim AS build
    [Error] Some services failed to build:
    [Error] Service: balena-hello-world
    [Error] Error: no matching manifest for linux/arm/v6 in the manifest list entries
    [Info] Built on a8df1a3
    [Error] Not deploying release.
    Remote build failed

PS D:\Balena\balena-nodejs-hello-world-master>

Now I am lost! Any help will be much appreciated.

The build stops at the base image, before it reaches your application code:

FROM node:22-bookworm-slim AS build
no matching manifest for linux/arm/v6

The Docker Official Images manifest currently lists that tag for amd64, arm32v7, arm64v8 and ppc64le, but not arm32v6. So the requested ARMv6 image is missing for that particular tag. Your log doesn’t point to the fleet name or the earlier CRLF conversion as the failing step.

I also checked the current balena Node hello-world Dockerfile.template: it uses the same tag in both its build and runtime stages. That makes this worth reporting as a compatibility problem in the example, with your device type and this build log.

I’d avoid just changing the tag to an ARMv7 image. Any replacement needs ARMv6 support and compatible build instructions in both stages. I haven’t tested a replacement on a Zero W, so I can’t promise a drop-in fix. Could you confirm the exact device type selected for the fleet and paste your Dockerfile.template?

Hi,

Thanks for your response.
The device selected is: Raspberry Pi (v1 / Zero / Zero W)
I have been following the Getting started documentation for the above device and nowhere does it mention Dockerfile Template so I have no idea what this is or how to find it if it has been created automatically.I hope this helps.

Regards,

$Richard Slater

Thanks, that confirms it: Raspberry Pi (v1 / Zero / Zero W) is an ARMv6 device, so “no matching manifest for linux/arm/v6” is exactly the failure to expect from that base image tag.

On the Dockerfile template question: nothing is created automatically. Dockerfile.template is simply a file that ships inside the project you downloaded. You are already working in that folder - your build log shows D:\Balena\balena-nodejs-hello-world-master, and Dockerfile.template sits right at the top of it, next to docker-compose.yml and package.json. You can open it with any text editor.

What it is: a balena-specific variant of a normal Dockerfile. balena’s builders can substitute placeholders like %%BALENA_MACHINE_NAME%% at build time (documented in balena’s “Define a container” docs under “Dockerfile templates”). The same docs note that for new projects balena recommends plain Dockerfiles with multi-platform base images instead, where the builder pulls the right architecture for your fleet’s device type automatically. The hello-world template does not actually use any placeholders, so you can treat it as an ordinary Dockerfile.

The concrete fix lives in that file. Both of its FROM lines point to node:22-bookworm-slim, which has no linux/arm/v6 manifest. The node:22-alpine tag does list linux/arm/v6 (I checked the official Docker manifest lists today). So change both FROM lines - the AS build stage and the runtime stage - from node:22-bookworm-slim to node:22-alpine, save, and run balena push Dicks-fleet-1 again.

One honest caveat: I have not run this build on a Zero W myself. The architecture support is verified against the official manifests, but alpine is a different base (musl instead of glibc). For a plain Node.js web server like this example that is normally fine; anything compiling native modules would be the thing to watch. If the build still fails, paste the new log here and I will take another look.

Separately, it may be worth reporting to balena that the current Node hello-world example no longer builds out of the box on ARMv6 devices like the Zero W.

Thanks very much Rei for your time and effort.
I made the changes you listed and it now builds successfully. Now I will continue to learn about Balena.

Regards,

Richard Slater.

You’re welcome, Richard - glad to hear it builds now. Have fun exploring balena!