honor containers.conf http_proxy and env settings during build #6996
All Vouch review confidence checks passed
Residual risk 0.16 = Change Risk (0.40) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.40 · 297 lines diff across 3 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.341
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #6996"
general
weight: 0.35
simonbrauner
What type of PR is this?
/kind bug
What this PR does / why we need it
This PR resolves an issue where
podman buildignoredcontainers.confsettings (http_proxy = falseand[containers] env). Please also see the linked issue for more context.1. Binds the
--http-proxyCLI flag default inpkg/cli/common.gotoContainers.HTTPProxyfromcontainers.confinstead of hardcodingtrue. This makes build proxy flag defaults consistent withpodman run, allowinghttp_proxy = falseincontainers.confto disable host environment proxy passthrough by default.2. Updates
configureEnvironment()inrun_common.goto inject environment variables defined under[containers] envincontainers.confinto the transient container process spec (g.AddProcessEnv) duringRUNsteps. This fixes the regression from pre-6.0.x wherecontainers.confenvironment settings applied to build execution commands (e.g. package management and network requests).How to verify it
1. Configure
containers.conf:2. Export host shell environment variables:
3. Run build:
4. Verify output contains
http_proxy=http://host.containers.internal:1080instead ofhttp://127.0.0.1:1080.Which issue(s) this PR fixes
Fixes: https://github.com/podman-container-tools/podman/issues/29299
Special notes for your reviewer
g.AddProcessEnvinconfigureEnvironment()sets the process spec environment (g.Config.Process.Env) for transient container execution duringRUNsteps. It does not touchbuilder.OCIv1.Config.Env, ensuring that environment variables configured incontainers.confapply to build execution without polluting committed image layers.Does this PR introduce a user-facing change?
Not sure if a release note is needed for regressions, but this does contain user-facing change:
``
release-notecontainers.confHonor
http_proxyandenvsettings during image builds, aligning the behavior withpodman runand fixed regression introduced in 6.0.x.
``