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

main: add ostree integration (HMS-5302) #53

Merged
merged 1 commit into from
Jan 10, 2025
Merged

Conversation

mvo5
Copy link
Collaborator

@mvo5 mvo5 commented Jan 8, 2025

This commit adds integration for the ostree options. It is modelled loosely after weldr-client/composer-cli and the

start-ostree --{ref,parent,url}

and uses

--ostree-{ref,parent,url}

This now has a smoke test based on fedora-iot, ideas for improvements here are welcome!

/jira-epic COMPOSER-2418

JIRA: HMS-5302

@mvo5 mvo5 assigned supakeen and unassigned supakeen Jan 8, 2025
@mvo5 mvo5 requested a review from supakeen January 8, 2025 20:58
@mvo5 mvo5 marked this pull request as ready for review January 9, 2025 14:53
@mvo5 mvo5 requested a review from ondrejbudai January 9, 2025 14:54
Copy link
Member

@ondrejbudai ondrejbudai left a comment

Choose a reason for hiding this comment

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

How does this behave if --ostree* is given to a non-ostree image type? We should probably return an error. Same for the opposite case - no ostree options for an ostree-enabled image type.

@mvo5
Copy link
Collaborator Author

mvo5 commented Jan 10, 2025

How does this behave if --ostree* is given to a non-ostree image type? We should probably return an error. Same for the opposite case - no ostree options for an ostree-enabled image type.

Thanks for the review! I added two tests that ensure the cases are handled correctly.

@mvo5 mvo5 force-pushed the add-ostree branch 2 times, most recently from f07d109 to 551b43c Compare January 10, 2025 10:30
@supakeen
Copy link
Member

Seems like there are some actual test case failures while building the RPMs:

--- FAIL: TestManifestIntegrationOstreeSmokeErrors (0.06s)
    main_test.go:299: 
        	Error Trace:	/builddir/build/BUILD/image-builder-cli-4/_build/src/github.com/osbuild/image-builder-cli/cmd/image-builder/main_test.go:299
        	Error:      	Error message not equal:
        	            	expected: "iot-raw-image: ostree commit URL required"
        	            	actual  : "cannot find image for: distro:\"fedora-40\" type:\"iot-raw-image\" arch:\"s390x\""
        	Test:       	TestManifestIntegrationOstreeSmokeErrors

@schutzbot schutzbot changed the title main: add ostree integration main: add ostree integration (HMS-5302) Jan 10, 2025
@schutzbot schutzbot added the 🌟 best practice This pull request follows our best practices! label Jan 10, 2025
This commit adds integration for the ostree options. It is modelled
loosely after weldr-client/composer-cli and the
```
start-ostree --{ref,parent,url}
```
and uses
```
--ostree-{ref,parent,url}
```

A simple smoke test is provided that uses fedora-iot. Ideas welcome
for an easier way :)
@supakeen supakeen added this pull request to the merge queue Jan 10, 2025
Merged via the queue into osbuild:main with commit 8f94516 Jan 10, 2025
27 of 28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🌟 best practice This pull request follows our best practices!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants