OpenWRT Docker image build failed

I use golang build a hellomips bin program without any dynamic link library, can run it on MT7621(MIPS32) OpenWRT 22.03.4.

# ./hellomips
hello mips

# ldd hellomips
ldd: hellomips: Not a valid dynamic program

Create Dockerfile, it's content as follow:

FROM scratch
ADD ./hellomips /
CMD ["/hellomips"]

Compile the dockerfile into an image:

# docker build -t hello .
Sending build context to Docker daemon  5.581MB
Step 1/3 : FROM scratch
 --->
Step 2/3 : ADD ./hellomips /
 ---> a7731a3615e0
Step 3/3 : CMD ["/hellomips"]
operation not supported

Build failed.

Why does an error occur when executing the step 3/3 CMD?

Is there a docker image that MIPS32 can run?

Oh, It missing fuse-overlayfs_1.7.1-1_mipsel_24kc.ipk and kmod-fuse_5.10.176-1_mipsel_24kc.ipk packages, causing the error.

Solved after installation.|

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.