-
Notifications
You must be signed in to change notification settings - Fork 7.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
build: add example on how to use proxy with GHA #17483
Conversation
✅ Deploy Preview for docsdocker ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
I wonder if we also need a page in "Building images" with a proxy page because we also need to explain that the proxy configuration from the Docker config is used if detected (see https://github.com/crazy-max/docker-build-push-action/blob/6509d7e99a330cd52fb169549758512aa83ca878/.github/workflows/ci.yml#L1021-L1040).
We also need to explain how to set proxy build args when doing a build instead of global daemon set: https://docs.docker.com/engine/reference/builder/#predefined-args. This will only work for RUN
instructions and not for pulling imaging or fetching git repos. For this case it needs to be set in buildkit as env driver opt.
Let me know what sounds best
@crazy-max proxy configurations are described on this page, it includes information about config.json. It also describes how these settings are used for building, and using build-arg |
Signed-off-by: David Karlsson <david.karlsson@docker.com> Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
3c75d39
to
d2c7655
Compare
|
||
The Docker GitHub Actions use the | ||
[`docker-container` driver](../../drivers/docker-container.md) by default, | ||
which supports setting environment variables through driver options. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not blocking this but it might be somewhat confusing to new readers why anyone would like to do this.
If we talk about just setting environment variables to buildkit containers then this could be in configure-builder
where it is showing some other driver-opts like setting image.
For configuring a proxy for builds we usually mean either passing proxy env as with --build-arg
or configuring the proxy setting in Docker CLI conf where buildx reads them.
Thanks for the pull request. We'd like to make our product docs better, but haven’t been able to review all the suggestions. If the updates are still relevant, review our contribution guidelines and rebase your pull request against the latest version of the docs, then mark it as fresh with a Prevent pull requests from auto-closing with a /lifecycle stale |
Signed-off-by: David Karlsson david.karlsson@docker.com
Proposed changes
Adds an example on how to set up a proxy with Docker GitHub Actions
Related issues (optional)
docker/build-push-action#822