mirror of
https://github.com/nektos/act.git
synced 2026-04-25 17:05:50 +03:00
[PR #2723] feat: Enable passing of proxy variables to Docker build #2575
Labels
No labels
area/action
area/cli
area/docs
area/image
area/runner
area/workflow
backlog
confirmed/not-planned
kind/bug
kind/discussion
kind/external
kind/feature-request
kind/question
meta/duplicate
meta/invalid
meta/need-more-info
meta/resolved
meta/wontfix
meta/workaround
needs-work
pull-request
review/not-planned
size/M
size/XL
size/XXL
stale
stale-exempt
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/act#2575
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/nektos/act/pull/2723
Author: @john-tipper
Created: 4/5/2025
Status: 🔄 Open
Base:
master← Head:#2722-docker-build-proxy-vars📝 Commits (7)
8e04748Enable passing of proxy variables to Docker build6b8ca1aPass params from command line6e864e1Update docker_build.go985066dAmend lint & fmt checks6d6e8c5Add tests3e54973Allow passing custom variables to docker build process by key71674f6Merge branch 'master' into #2722-docker-build-proxy-vars📊 Changes
8 files changed (+191 additions, -2 deletions)
View changed files
📝
cmd/input.go(+1 -0)📝
cmd/root.go(+8 -0)📝
pkg/container/container_types.go(+1 -0)📝
pkg/container/docker_build.go(+26 -2)➕
pkg/container/docker_build_test.go(+41 -0)📝
pkg/runner/action.go(+19 -0)📝
pkg/runner/action_test.go(+94 -0)📝
pkg/runner/runner.go(+1 -0)📄 Description
Resolves #2722.
This PR adds a flag called
--pass-proxy-vars-to-docker-build--pass-envvars-to-docker-buildwhich allows the user to pass proxy variables through to the build of Docker-based actions. These variables are HTTP_PROXY, HTTPS_PROXY and NO_PROXY, plus the lowercase versions too because not all applications respect all cases.The variables that are set are taken from the environment of Act itself. If the URL includes a password then this is redacted when logging the command passed to Docker.
This PR allows Act to be used within an enterprise environment where access to the internet is via an authenticating proxy, otherwise Docker-based actions are not able to be used if they need to access the internet as part of their build process.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.