CHEF-37332: add Linux ARM Habitat validation in Expeditor pipeline - #193
Open
sanjain-progress wants to merge 5 commits into
Open
CHEF-37332: add Linux ARM Habitat validation in Expeditor pipeline#193sanjain-progress wants to merge 5 commits into
sanjain-progress wants to merge 5 commits into
Conversation
Add an Arm64 Habitat validation step to .expeditor/habitat-test.pipeline.yml using Buildkite queue default-privileged-aarch64, docker plugin (ruby:3.4), and BUILD_PKG_TARGET=aarch64-linux, keeping HAB_AUTH_TOKEN propagation consistent with existing Linux/Windows steps. Also introduce habitat/aarch64-linux/plan.sh, sourcing the existing habitat/plan.sh to reuse the default Linux build logic for aarch64 (ARM) targets. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: Sachin Jain <Sachin.jain@chef.io>
sanjain-progress
marked this pull request as ready for review
July 31, 2026 08:42
Signed-off-by: Sachin Jain <Sachin.jain@chef.io>
Use $SRC_PATH/VERSION instead of the relative ../VERSION path so pkg_version() resolves correctly regardless of which directory depth the plan is invoked from. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: Sachin Jain <Sachin.jain@chef.io>
do_unpack, the NOTICE copy, and the binstub_patch.rb injection all assumed the plan is always invoked one directory below the repository root. Resolve the actual repository root via git instead, so these steps work correctly no matter which directory depth invokes the plan. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: Sachin Jain <Sachin.jain@chef.io>
The Habitat build sandbox mounts the source tree with different ownership, causing git to refuse operations with a 'dubious ownership' error. Mark directories as safe before invoking git rev-parse so _repo_root resolves correctly inside the sandbox. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: Sachin Jain <Sachin.jain@chef.io>
sanghinitin
approved these changes
Aug 3, 2026
ashiqueps
approved these changes
Aug 3, 2026
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.
Summary
Adds Linux ARM64 (aarch64) Habitat build validation to the Knife Expeditor/Buildkite pipeline, and fixes the Habitat plan to build correctly when invoked from the new ARM target directory.
What Changed
":linux: Arm64 Validate Habitat Builds of Knife"step to.expeditor/habitat-test.pipeline.ymldefault-privileged-aarch64docker#v3.5.0plugin with imageruby:3.4.2-bullseye,privileged: true,propagate-environment: trueBUILD_PKG_TARGET: "aarch64-linux"HAB_AUTH_TOKENpropagated via the environment, consistent with the existing Linux/Windows stepshabitat/aarch64-linux/plan.sh, sourcing the existinghabitat/plan.shto reuse the default Linux build logic for aarch64 (ARM) targetshabitat/plan.shso the build works correctly regardless of which directory depth the plan is invoked from (habitat/for the default target vs.habitat/aarch64-linux/for the new ARM target):pkg_version()now reads$SRC_PATH/VERSIONinstead of the relative../VERSION, which resolved to the wrong file when invoked from the ARM plan_repo_root()helper that resolves the repository root viagit rev-parse --show-topleveldo_unpack()now copies the full repository root (via_repo_root()) into the Habitat build cache, instead of a fixed$PLAN_CONTEXT/.., which previously copied too shallow a tree and caused the build to fail withCould not locate GemfileNOTICEcopy andbinstub_patch.rbinjection indo_install()also use_repo_root()for the same reason_repo_root()marks all directories as git-safe first, since the Habitat build sandbox mounts the source tree with different ownership, which otherwise causes git to fail with a "dubious ownership" errorResult
Habitat package builds for Knife are now validated on Linux ARM64 via Buildkite/Expeditor, in addition to the existing Linux (x86_64) and Windows validation steps, and the Habitat plan builds successfully on both the default and ARM targets.
Jira
CHEF-37332