Skip to content

stage0: ostree support#11

Merged
samcday merged 2 commits intomainfrom
fastboop-ostree
Feb 17, 2026
Merged

stage0: ostree support#11
samcday merged 2 commits intomainfrom
fastboop-ostree

Conversation

@samcday
Copy link
Owner

@samcday samcday commented Feb 16, 2026

closes #4

Signed-off-by: Sam Day <me@samcday.com>
Assisted-by: opencode:gpt-5.3-codex
@samcday
Copy link
Owner Author

samcday commented Feb 16, 2026

@codex review

@chatgpt-codex-connector
Copy link

Codex Review: Didn't find any major issues. Chef's kiss.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Owner Author

@samcday samcday left a comment

Choose a reason for hiding this comment

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

@codex scan you reshuffle this code a bit per comments

cmdline_flag(key)
}

fn detect_ostree_layout(newroot: &Path) -> Result<Option<OstreeLayout>> {
Copy link
Owner Author

Choose a reason for hiding this comment

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

Move all the ostree stuff into an ostree.rs module

}

#[test]
fn normalize_cmdline_path_strips_root_prefix() {
Copy link
Owner Author

Choose a reason for hiding this comment

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

Make sure the tests move to the new ostree.rs module as well.

@chatgpt-codex-connector
Copy link

On it

@chatgpt-codex-connector
Copy link

Summary

  • Refactored stage0 to load OSTree logic from a dedicated ostree module by adding mod ostree; and importing the module entry points in main.rs, while preserving the existing call flow in PID1 handoff/mount setup. stage0/src/main.rsL4-L5 stage0/src/main.rsL381-L437
  • Moved all OSTree-specific implementation (layout detection, cmdline normalization, stateroot path derivation, boot bind decision, and runtime mount setup) into stage0/src/ostree.rs. stage0/src/ostree.rsL1-L251
  • Moved the OSTree unit tests into the new ostree module, as requested in review comments. stage0/src/ostree.rsL253-L290
  • Committed changes on the current branch (02cf853) and created a follow-up PR record with title “Follow-up: move stage0 OSTree code into ostree module”.

Testing

  • ⚠️ curl -L 'https://duckduckgo.com/html/?q=rust+move+functions+to+module+tests+same+file' -o /tmp/websearch.html && echo 'web search done' && rg -n "rust" /tmp/websearch.html | head (blocked by environment proxy/403)
  • cargo fmt
  • cargo check -p fastboop-stage0
  • cargo test -p fastboop-stage0

View task →

@samcday samcday merged commit 7096598 into main Feb 17, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support ostree boots

1 participant

Comments