Reputation: 301
I have a Dockerfile which includes (for example):
RUN wget https://updates.jenkins.io/download/plugins/SBuild/1.0.2/SBuild.hpi
and I try to build it directly from my machine:
buildah bud -t myimage .
works.
When I try to build this from inside a container (call it containerX) running inside Kubernetes, the command stays there forever/fails. However, the wget works when run directly from the containerX.
I can work it around by downloading the artifacts from containerX and copy it into the target container/image. However, it will take off the flexibitlity as it involves more files and also I am trying to understand what is going on here.
To summarise buildah:
containerX -> Ubuntu 24.04 LTS
buildahContainer -> Debian GNU/Linux 12 (bookworm)
kubernetes -> MicroK8s v1.28.9 revision 6750
Please let me know if you need more information in this regard.
Thanks for your time.
UPDATE: Playing further with it, I observed the following:
--network host
(which is undesirable) all worksUpvotes: 0
Views: 80