Can't compile node on Pi3

Hi there,
I’m having issues installing nodejs through docker.
It was working since yesterday so I’m not sure if it’s related to balena.

Here’s my docker file:
FROM tobi312/rpi-nginx

RUN apt-get update && \
    apt-get install -y apt-transport-https telnet nano iputils-ping less kmod nano net-tools ifupdown i2c-tools libcairo2-dev libjpeg-dev libpango1.0-dev libgif-dev build-essential libssl-dev g++ samba avahi-daemon avahi-discover wget curl cups printer-driver-gutenprint usbutils gphoto2 imagemagick build-essential && \
    apt-get clean && \
    rm -rf /var/lib/apt/lists/*

# node install
RUN curl -sL | sudo -E bash -
RUN apt-get install -y nodejs

RUN useradd pi && \
    echo "user ALL=(root) NOPASSWD:ALL" > /etc/sudoers.d/user && \
    chmod 0440 /etc/sudoers.d/user && \
    echo "pi:raspberry"|chpasswd && \
    usermod -a -G lpadmin pi

# RUN wget && chmod +x && sudo ./ --development

# Defines our working directory in container
WORKDIR /usr/src/app

# Copies the package.json first for better cache on later pushes
COPY ./package.json package.json

COPY ./cupsd.conf /etc/cups/cupsd.conf
COPY ./printers.conf /etc/cups/printers.conf

# This install npm dependencies on the build server,
# making sure to clean up the artifacts it creates in order to reduce the image size.
RUN npm install pm2 -g --no-optional
RUN JOBS=MAX npm install --production --unsafe-perm && rm -rf /tmp/*

# This will copy all files in our root to the working  directory in the container
COPY . ./

# Enable systemd init system in container

CMD ["bash", ""]

See error in attachment,
please let me know if you can identify the cause, thanks

I’m not sure why this would have suddenly stopped working, it seems like it should have. Did you make any other changes to the Dockerfile prior to it not working. Perhaps it would be easier to use a balenalib base image with node-preinstalled, e.g. balenalib/raspberrypi3-node:10

You could then install nginx inside of the docker file instead, but I’m not sure why the dockerfile in it’s current iteration doesn’t work.

Yeah, that’s weird. I didn’t change anything since the last time it worked.
Unfortunately changing the base image could cause many unexpected bugs since it’s a pretty delicate multicontainer application.

Looking at the script returned from that url ( there should be some output, but I don’t see any in the build. Have you tried to build this image locally?

I just tried to install it locally (nodejs with the same method) on the Pi and it was installed correctly so I don’t think it’s related to that

Maybe try running with bash -e so we can see what the script is doing after being pulled down. It should print some information then run apt-get update, but in the screenshot you posted, it doesn’t appear to be doing that.

I tried but still no output,
can it be related to caching?
How do I force balena to rebuild the image without caching? I tried with --force without luck,

I think the problem could be related to the tobi312/rpi-nginx image being updated yesterday
I will dig further

We have been seeing similar issues with updates to buster, documented here:

yep, the new tag for that image installed buster.
I pulled the previous tag and it’s now working
FROM tobi312/rpi-nginx:1.10

thanks for your help

Not a problem.