Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bib: allow blueprints in toml as well #392

Merged
merged 3 commits into from
Apr 26, 2024
Merged

Conversation

mvo5
Copy link
Collaborator

@mvo5 mvo5 commented Apr 25, 2024

This commit adds support to load blueprints from toml as well.

[draft as tests are missing]

@achilleas-k
Copy link
Member

achilleas-k commented Apr 25, 2024

I expressed a preference for toml to make life easier for adding kickstart files (see osbuild/images#631). What I'd like to see, either in this PR or a follow-up:

  • Automatic detection of /config.toml like we do for /config.json.
  • Prioritise toml in docs (downstream docs should be aware of this too).
  • Move the config one level down, so the blueprint is the top level object, just like in osbuild-composer (this is optional; might be good to have the blueprint as a second level if we want to add BIB specific config options that don't come from the osbuild-composer blueprint).

The latest one should be a followup

@mvo5 mvo5 force-pushed the use-toml-blueprints branch 2 times, most recently from 3db0b40 to ac2e650 Compare April 25, 2024 18:17
This commit adds support to load blueprints from toml as well.
@mvo5 mvo5 requested a review from achilleas-k April 25, 2024 18:39
@mvo5 mvo5 marked this pull request as ready for review April 25, 2024 18:39
@henrywang
Copy link
Member

I have one suggestion on this feature. It will be wonderful to align this toml configuration file with toml file used by osbuild-composer. So the osbuild-composer Blueprint Refreence can be re-used as a reference. Thanks!

Move from config.json -> config.toml in the example(s) in th
README.md.

Also remove the `--config` as bib will search for /config.{json,toml}
automatically.
Tiny integration test that ensures config.toml is honored during
manifest generation.
@achilleas-k
Copy link
Member

I have one suggestion on this feature. It will be wonderful to align this toml configuration file with toml file used by osbuild-composer. So the osbuild-composer Blueprint Refreence can be re-used as a reference. Thanks!

Since we use a very limited number of options here, it might be better to have a dedicated page for BIB. Or maybe we could add a third bubble colour for bootc-image-builder like we have for on-prem vs console.

@mvo5
Copy link
Collaborator Author

mvo5 commented Apr 26, 2024

I have one suggestion on this feature. It will be wonderful to align this toml configuration file with toml file used by osbuild-composer. So the osbuild-composer Blueprint Refreence can be re-used as a reference. Thanks!

Since we use a very limited number of options here, it might be better to have a dedicated page for BIB. Or maybe we could add a third bubble colour for bootc-image-builder like we have for on-prem vs console.

I have a branch ready for this in https://github.com/osbuild/bootc-image-builder/compare/main...mvo5:use-toml-blueprints-compat?expand=1 - it also keeps the legacy format compatiblity for now

Copy link
Member

@achilleas-k achilleas-k left a comment

Choose a reason for hiding this comment

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

Excellent. LGTM!

bib/internal/buildconfig/config.go Show resolved Hide resolved
@mvo5 mvo5 added this pull request to the merge queue Apr 26, 2024
Merged via the queue into osbuild:main with commit f31ceb4 Apr 26, 2024
7 of 9 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.

3 participants