Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .buildkite/hooks/pre-command
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@ if [[ "$BUILDKITE_PIPELINE_SLUG" == "auditbeat" || \
export BUILDKITE_ANALYTICS_TOKEN
fi

# Ensure the required mage version is installed (the CI agent image may not have it)
if [[ -n "${ASDF_MAGE_VERSION:-}" ]] && command -v asdf &>/dev/null; then
asdf install mage "$ASDF_MAGE_VERSION"
fi

Comment on lines +31 to +35
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Missing changelog fragment.

This bug fix should include a changelog fragment in changelog/fragments/. Create one via:

go install github.com/elastic/elastic-agent-changelog-tool@latest
elastic-agent-changelog-tool new "Install mage via asdf if missing in pre-command hook"

Set kind: bug-fix and component: ci (or appropriate component). Based on learnings from this repository.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.buildkite/hooks/pre-command around lines 31 - 35, The change adds an
asdf-based mage install in the pre-command hook but lacks a changelog fragment;
generate a fragment using the elastic-agent-changelog-tool (run: go install
github.com/elastic/elastic-agent-changelog-tool@latest and
elastic-agent-changelog-tool new "Install mage via asdf if missing in
pre-command hook"), place the generated file under changelog/fragments/, and set
metadata kind: bug-fix and component: ci (or appropriate component) so the PR
includes the required changelog entry referencing the pre-command hook change
that installs mage when ASDF_MAGE_VERSION is set.

CPU_ARCH=$(uname -m)
PLATFORM_TYPE=$(uname)

Expand Down
Loading