ktock/container2wasm

Failed to solve process "apt-get" for golang-base container

allogic opened this issue · 5 comments

It seems that the golang-base has some problems when converting.

38.67 Reading package lists...
38.69 Building dependency tree...
38.70 Reading state information...
38.70 E: Unable to locate package gperf
------
container2wasm2433911993:337
--------------------
 335 |     FROM golang-base AS runc-amd64-dev
 336 |     ARG RUNC_VERSION
 337 | >>> RUN apt-get update -y && apt-get install -y git make gperf
 338 |     RUN --mount=type=cache,target=/root/.cache/go-build \
 339 |         --mount=type=cache,target=/go/pkg/mod \
--------------------
ERROR: failed to solve: process "/bin/sh -c apt-get update -y && apt-get install -y git make gperf" did not complete successfully: exit code: 100
exit status 1

Thanks for reporting the issue. What is the host environment (OS,arch) and docker version? Are you using proxies or something?

It is ubuntu running in the WSL (Win11):
Linux XXX 5.10.102.1-microsoft-standard-WSL2 #1 SMP Wed Mar 2 00:30:59 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

Docker version with the WSL support enabled instead of Hyper-V:
Docker version 26.1.0, build 9714adc

No proxies are being used.

I've worked with this setup alot and never noticed a problem until now.

Does the gperf issue occur in the normal container (not c2w) as well? i.e. docker run --rm -it golang:1.21-bullseye /bin/sh -c "apt-get update -y && apt-get install -y gperf"

Yes this worked!
It seems there is some issue with the network inside the WSL..

Thanks for trying it. I'll close this issue as it seems to be solved.