Skip to content

Conversation

@djeebus
Copy link
Contributor

@djeebus djeebus commented Nov 27, 2025

this makes it easier to read the individual files and for linters to parse them.


Note

Embeds rootfs system files as templates and refactors build/provisioning to use them, adds tests, fixes OCI layer paths, and tweaks benchmark logging.

  • Rootfs/Build System:
    • Embed rootfs files via embed.FS and render using Go templates (files/*.tpl).
    • Introduce templateModel (with .WriteFile, MemoryLimit) and addTemplatedFilesToMap to generate file map.
    • Centralize constants (ProvisionExitPrefix, ProvisionLogPrefix, paths) and replace inline strings.
    • Simplify CreateExt4Filesystem/additionalOCILayers signatures and usage.
  • Build Phases:
    • Remove ad-hoc provision script generation; consume rootfs constants/APIs.
    • Update hashing to use rootfs.ProvisionScriptFile.
  • OCI:
    • Normalize layer entry names by trimming leading / in layer_file.go.
  • Tests:
    • Add rootfs/rootfs_test.go to validate generated files in the OCI layer.
  • Benchmark:
    • Switch to zap dev logger with whitespace-stripping core in benchmark_test.go.

Written by Cursor Bugbot for commit bc0adf7. This will update automatically on new commits. Configure here.

this makes it easier to read the individual files and for linters to parse them.
@djeebus djeebus marked this pull request as ready for review December 1, 2025 18:19
@chatgpt-codex-connector
Copy link

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Credits must be used to enable repository wide code reviews.

Copy link
Contributor

@dobrac dobrac left a comment

Choose a reason for hiding this comment

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

one nit, but LGTM 🚀

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.

4 participants