Open diana-zvulun opened 8 months ago
You need to enable this capability in buildkitd config to allow build request to use it because host network is considered insecure.
Insecure entitlements from https://github.com/moby/buildkit/blob/master/docs/buildkitd.toml.md
Is there a way to configure it as args to the container?
Right now these are my arguments:
args: "--addr unix:///run/buildkit/buildkitd.sock --addr tcp://xxx.xxx.xxx.xxx:1234"
I couldn't find anything in the documentation. This is the buildctl command I've used so far but it doesn't look like it worked:
buildctl --addr tcp://xxx.xxx.xxx.xxxx:xxxx build --frontend dockerfile.v0 --local context=. --local dockerfile=/docker/ --opt network=host --output type=image,'\"name=repo/repo-name:latest\"',push=true"
Also when adding these options:
--opt force-network-mode=host --allow=network.host --allow=security.insecure
I get this error:
failed to solve: granting entitlement network.host is not allowed by build daemon configuration