Guard unzboot copy by arch in rhel10 DTK entrypoint - #987
Closed
lukiod wants to merge 1 commit into
Closed
Conversation
install.sh only installs /usr/bin/unzboot when DRIVER_ARCH is aarch64 (RHEL10 arm64 kernel images use the zboot format). ocp_dtk_entrypoint copied it unconditionally on both sides, so the amd64 DTK path fails before any build starts: cp: cannot stat '/usr/bin/unzboot'. Guard both copies by architecture, matching install.sh's own condition. Signed-off-by: Mohak Gupta <mohakgupta0981@gmail.com>
Author
|
duplicate of #986, already fixes the same issue, closing this one |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #984.
install.shonly installs/usr/bin/unzbootwhenDRIVER_ARCHisaarch64(RHEL10 arm64 kernel images use the zboot format, per the comment at rhel10/install.sh:56).ocp_dtk_entrypointcopies it unconditionally on both the producer side (line ~42, shared-dir prep) and the consumer side (line ~178, DTK-sidebin/staging), so on amd64 the DTK path fails before any build starts:Guarded both copies by architecture:
$TARGETARCH == "arm64"on the producer side (that's the only arch signal available at that point in the script), and$DRIVER_ARCH == "aarch64"on the consumer side, matching the variable already computed there a few lines earlier. Neither guard changes behavior on arm64/aarch64, unzboot still gets copied on both sides exactly as before.Verification. No RHEL10/OCP DTK environment available to run this end to end, so I simulated both code paths directly against fake files standing in for the real ones: on amd64 the copy block now completes with no unzboot present and no error (previously reproduced the exact reported failure); on arm64/aarch64 unzboot is still correctly copied on both sides. Ran
bash -nfor a syntax check, clean.