mirror of
https://github.com/hanzoai/pack.git
synced 2026-09-30 23:43:13 +00:00
fix(build): respect configured deploy input filters (#562)
* Respect configured deploy inputs for config steps When a config-defined step already has an explicit deploy input, Railpack should not append the implicit deploy output for the entire step. This preserves include filters such as Next.js standalone output selections and avoids copying the full build step into the final image. Constraint: Config steps without explicit deploy inputs still need the existing implicit deploy output behavior. Rejected: Change deploy input filter semantics globally | too broad for this bug and risks provider output behavior. Confidence: medium Scope-risk: moderate Tested: go test ./core/generate -run 'TestHasInputForStep|TestGenerateContextKeepsConfiguredDeployInputFilters' Tested: go test ./core/generate -run TestHasIncludeForStep Tested: go test ./core/generate Tested: git diff --check * fix(generate): respect explicitly configured deploy inputs without implicit steps - Prevent implicit deploy step outputs from being added when explicit deploy inputs are configured without a spread operator. - Add comprehensive test coverage for various deploy input and output combinations. Generated-by: aiautocommit * feat(examples): respect configured deploy inputs - Add `/usr/games` to runtime paths to support Debian's cowsay installation location in the config example. - Assert that unrelated files do not leak through implicit deploy outputs. Generated-by: aiautocommit * refactor(generate): check configured deploy inputs for step Generated-by: aiautocommit --------- Co-authored-by: Michael Bianco <[email protected]>
This commit is contained in:
committed by
GitHub
co-authored by
Michael Bianco
parent
392d3fef96
commit
005f7bef04
@@ -5,4 +5,10 @@ if [ "$(cat /hello)" != "world" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# /boop comes from an unrelated step and must not leak through implicit deploy outputs.
|
||||
if [ -e /boop ]; then
|
||||
echo "Error: implicit deploy output copied /boop"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "custom start!"
|
||||
|
||||
@@ -19,6 +19,8 @@
|
||||
{ "local": true, "include": ["custom-start.sh"] }
|
||||
],
|
||||
"aptPackages": ["cowsay"],
|
||||
// Debian installs cowsay in /usr/games, which is not on the runtime PATH.
|
||||
"paths": ["/usr/games"],
|
||||
"startCommand": "neofetch && cowsay hello && ./custom-start.sh"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user