Docker build fails on docker hub

I am trying to build an image for raspberry pi zero based on arm32v6/node image but the build fails when using docker hub infra for image build. I am able to build the image with docker buildx using docker desktop version. I came across a post from hypriot which states the we need to register QEMU in the build agent. I am not sure what that means and how to configure. I followed the steps mentioned on the post but the build still fails. I am using automated build with bitbucket and git repo.

I am new to all this and would appreciate any help.

Thanks.

hypriot : https://blog.hypriot.com/post/setup-simple-ci-pipeline-for-arm-images/

Docker error :

Step 4/9 : RUN apk add --update --no-cache make

---> Running in 1a693bfde97d

e[91mstandard_init_linux.go:211: exec user process caused "exec format error"

e[0m

Removing intermediate container 1a693bfde97d

Docker File :

FROM arm32v6/node:lts-alpine
COPY . /juice-shop
WORKDIR /juice-shop

# Installing MAKE
RUN apk add --update --no-cache make
RUN apk update \
    && apk add --virtual build-dependencies \
        build-base \
        gcc \
        wget \
        git \
    && apk add \
        bash

RUN addgroup juicer && \
    adduser -D -G juicer juicer

USER juicer
EXPOSE 3000
CMD ["/bin/bash"]

Hi Sumitraina,

Could you try replacing #!/bin/bash with #!/bin/sh at the last line?