Skip to content

butane: update Dockerfile and build script for ignition repo - #2256

Merged
prestist merged 1 commit into
coreos:mainfrom
prestist:butane-container
Aug 14, 2026
Merged

prestist merged 1 commit into
coreos:mainfrom
prestist:butane-container

Conversation

@prestist

Copy link
Copy Markdown
Collaborator

Summary

Update butane/Dockerfile and butane/build_for_container to work correctly from within the ignition repo after the Butane merge (#2235).

Changes

  • butane/Dockerfile -- Update Docker context from /butane to /ignition (repo root), run ./butane/build_for_container instead of ./build_for_container
  • butane/build_for_container -- Update import path from github.com/coreos/butane to github.com/coreos/ignition/v2/butane, use module path instead of internal/main.go

The CI workflow to build and push this container will come from coreos/repo-templates#371.

Tracking

Update butane/Dockerfile to use the ignition repo root as context
and run butane/build_for_container from there. Update the build
script to use the ignition module import path.
@coderabbitai

coderabbitai Bot commented Aug 12, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: f0e21800-138f-498a-b724-6f9439d87c37

📥 Commits

Reviewing files that changed from the base of the PR and between 3ec5322 and 42b80a8.

📒 Files selected for processing (2)
  • butane/Dockerfile
  • butane/build_for_container
📜 Recent review details
⏰ Context from checks skipped due to timeout. (8)
  • GitHub Check: Build container image
  • GitHub Check: Check binary size
  • GitHub Check: Test ignition-validate (1.26.x, windows-latest)
  • GitHub Check: Shellcheck
  • GitHub Check: Test (1.25.x)
  • GitHub Check: tmt-tests
  • GitHub Check: Test ignition-validate (1.26.x, macos-latest)
  • GitHub Check: Test (1.26.x)
⚠️ CI failures not shown inline (2)

GitHub Actions: Release notes / Require release note: butane: update Dockerfile and build script for ignition repo

Conclusion: failure

View job details

##[group]Run set -euo pipefail
 �[36;1mset -euo pipefail�[0m
 �[36;1mif [ -n "skip-notes" ]; then�[0m
 �[36;1m    # Don't trust the label list in the event metadata, since runs�[0m
 �[36;1m    # can be scheduled out of order and the list might be stale.�[0m
 �[36;1m    label=$(curl --no-progress-meter \�[0m
 �[36;1m        -H "Accept: application/vnd.github+json" \�[0m
 �[36;1m        -H "Authorization: token ***" \�[0m
 �[36;1m        "https://api.github.com/repos/coreos/ignition/pulls/2256" |�[0m
 �[36;1m        jq '.labels[] | select(.name == "skip-notes")')�[0m
 �[36;1m    if [ -n "${label}" ]; then�[0m
 �[36;1m        echo "PR has skip-notes label; skipping"�[0m
 �[36;1m        exit 0�[0m
 �[36;1m    fi�[0m
 �[36;1mfi�[0m
 �[36;1mdiffinfo=$(curl --no-progress-meter \�[0m
 �[36;1m    -H "Accept: application/vnd.github+json" \�[0m
 �[36;1m    -H "Authorization: token ***" \�[0m
 �[36;1m    "https://api.github.com/repos/coreos/ignition/compare/3ec532290ec952d00401e5aa7f5abad41aada6d4...42b80a8a5b36a469babcdd0bcd292ab02453ec11" |�[0m
 �[36;1m    jq '.files[] | select(.filename == "docs/release-notes.md")')�[0m
 �[36;1mif [ -z "${diffinfo}" ]; then�[0m
 �[36;1m    echo "Found no changes to docs/release-notes.md."�[0m
 �[36;1m    if [ -n "skip-notes" ]; then�[0m
 �[36;1m        echo "To ignore, add skip-notes label to PR."�[0m
 �[36;1m    fi�[0m
 �[36;1m    exit 1�[0m
 �[36;1mfi�[0m
 �[36;1mecho "Found change to docs/release-notes.md."�[0m
 shell: /usr/bin/bash --noprofile --norc -e -o pipefail {0}
 ##[endgroup]
 Found no changes to docs/release-notes.md.
 To ignore, add skip-notes label to PR.
 ##[error]Process completed with exit code 1.

GitHub Actions: Release notes / 0_Require release note.txt: butane: update Dockerfile and build script for ignition repo

Conclusion: failure

View job details

##[group]Run set -euo pipefail
 �[36;1mset -euo pipefail�[0m
 �[36;1mif [ -n "skip-notes" ]; then�[0m
 �[36;1m    # Don't trust the label list in the event metadata, since runs�[0m
 �[36;1m    # can be scheduled out of order and the list might be stale.�[0m
 �[36;1m    label=$(curl --no-progress-meter \�[0m
 �[36;1m        -H "Accept: application/vnd.github+json" \�[0m
 �[36;1m        -H "Authorization: token ***" \�[0m
 �[36;1m        "https://api.github.com/repos/coreos/ignition/pulls/2256" |�[0m
 �[36;1m        jq '.labels[] | select(.name == "skip-notes")')�[0m
 �[36;1m    if [ -n "${label}" ]; then�[0m
 �[36;1m        echo "PR has skip-notes label; skipping"�[0m
 �[36;1m        exit 0�[0m
 �[36;1m    fi�[0m
 �[36;1mfi�[0m
 �[36;1mdiffinfo=$(curl --no-progress-meter \�[0m
 �[36;1m    -H "Accept: application/vnd.github+json" \�[0m
 �[36;1m    -H "Authorization: token ***" \�[0m
 �[36;1m    "https://api.github.com/repos/coreos/ignition/compare/3ec532290ec952d00401e5aa7f5abad41aada6d4...42b80a8a5b36a469babcdd0bcd292ab02453ec11" |�[0m
 �[36;1m    jq '.files[] | select(.filename == "docs/release-notes.md")')�[0m
 �[36;1mif [ -z "${diffinfo}" ]; then�[0m
 �[36;1m    echo "Found no changes to docs/release-notes.md."�[0m
 �[36;1m    if [ -n "skip-notes" ]; then�[0m
 �[36;1m        echo "To ignore, add skip-notes label to PR."�[0m
 �[36;1m    fi�[0m
 �[36;1m    exit 1�[0m
 �[36;1mfi�[0m
 �[36;1mecho "Found change to docs/release-notes.md."�[0m
 shell: /usr/bin/bash --noprofile --norc -e -o pipefail {0}
 ##[endgroup]
 Found no changes to docs/release-notes.md.
 To ignore, add skip-notes label to PR.
 ##[error]Process completed with exit code 1.
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: PeaceRebel
Repo: coreos/ignition PR: 2239
File: .github/workflows/binary-size.yml:0-0
Timestamp: 2026-07-28T12:01:12.154Z
Learning: In `.github/workflows/binary-size.yml`, the workflow checks out and builds the current base SHA after building the PR revision. During the build-interface migration, the base branch may not contain the new Makefile targets, so the base build must retain its compatible `./build` invocation while the PR build can use `make ignition BIN_PATH=bin/amd64`.
📚 Learning: 2026-07-28T12:01:12.154Z
Learnt from: PeaceRebel
Repo: coreos/ignition PR: 2239
File: .github/workflows/binary-size.yml:0-0
Timestamp: 2026-07-28T12:01:12.154Z
Learning: In `.github/workflows/binary-size.yml`, the workflow checks out and builds the current base SHA after building the PR revision. During the build-interface migration, the base branch may not contain the new Makefile targets, so the base build must retain its compatible `./build` invocation while the PR build can use `make ignition BIN_PATH=bin/amd64`.

Applied to files:

  • butane/Dockerfile
🔇 Additional comments (2)
butane/build_for_container (1)

9-17: LGTM!

butane/Dockerfile (1)

4-6: 🩺 Stability & Availability

Preserve the repository root and Git metadata in the container build context.

COPY . /ignition requires the repository root as context. butane/build_for_container runs git describe --dirty --always; the build fails if the context excludes .git. Use a path context that includes .git, or update the script to accept an explicit version.


📝 Walkthrough

Walkthrough

The container build now checks out and builds from /ignition. The build script targets the relocated Ignition module packages and builds the butane/internal package.

Changes

Container build path update

Layer / File(s) Summary
Relocate container build targets
butane/Dockerfile, butane/build_for_container
The Dockerfile uses /ignition for the workspace and binary copy. The build script uses the relocated version package and builds butane/internal.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 6
✅ Passed checks (6 passed)
Check name Status Explanation
Title check ✅ Passed The title uses the required subsystem format, has a lowercase imperative description, and accurately summarizes the changes.
Description check ✅ Passed The description clearly explains the Dockerfile and build script updates and their purpose in the Ignition repository.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Commit Message Convention ✅ Passed The PR contains one non-merge commit: butane: update Dockerfile and build script for ignition repo; it uses a valid subsystem, lowercase imperative update, and no trailing period.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown

Binary size report (bin/amd64/ignition)

Size
Base (main) 33MiB
PR (#2256) 33MiB
Delta +0B (0.00%)

@prestist prestist added the skip-notes This PR does not need release notes label Aug 12, 2026

@yasminvalim yasminvalim left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@coderabbitai coderabbitai Bot mentioned this pull request Aug 13, 2026
@prestist
prestist merged commit 5300eed into coreos:main Aug 14, 2026
15 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-notes This PR does not need release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants