Skip to content

Commit

Permalink
preprocessor: do not honour CUE_UNSAFE_NETWORK_HOST in multi-step
Browse files Browse the repository at this point in the history
WIP

Preprocessor-No-Write-Cache: true
Signed-off-by: Paul Jolly <[email protected]>
Change-Id: I64664fb836cbfe1f7f0e1e94e417595d102e84ed
Dispatch-Trailer: {"type":"trybot","CL":1176742,"patchset":2,"ref":"refs/changes/42/1176742/2","targetBranch":"alpha"}
  • Loading branch information
myitcv authored and cueckoo committed Feb 12, 2024
1 parent fc293a8 commit 0258bd6
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions internal/cmd/preprocessor/cmd/rootfile.go
Original file line number Diff line number Diff line change
Expand Up @@ -579,12 +579,9 @@ func (m *multiStepScript) run() (runerr error) {
"-v", fmt.Sprintf("%s:/scripts", scriptsDir),
)

// If the user wants to be unsafe and _not_ isolate the network let them
// It results in much faster running times when working on changes in the
// preprocessor.
if os.Getenv("CUE_UNSAFE_NETWORK_HOST") != "" {
args = append(args, "--network=host")
}
// We cannot perform the --network=host trick here, even if the user wants
// to be unsafe. Because we run cue mod registry which requires its own
// networking isolation (for binding to the port it will use etc).

args = append(args,
// TODO: support per-guide docker images
Expand Down

0 comments on commit 0258bd6

Please sign in to comment.