Story #8919
closed
Story #8924: As a user, I can manage OSTree repositories
As a user, I can upload a Fedora IoT update image with OSTree commits to an existing repository
Description
-
Use the URL of an OSTree repository in Pulp and a ref in that repository to build a new Fedora IoT image in Image Builder.
-
Download the new image from Image Builder
-
Upload the new image into the existing repository in Pulp, optionally specify a new ref
-
Reboot a host that is using the Pulp repository for updates and confirm that it is able to retrieve the new updates.
In cases where the uploaded archive contains commits that are not children of any of the commits already in the repository, the upload still succeeds and clients are able to use them. The history from client's perspective will be limited to what was last uploaded. Pulp users will be able to roll back repository versions to expose more history if that is needed.
- Description updated (diff)
- Sprint/Milestone set to 2.0.0a1
The new image, does it have some kind of diff or will it replace what is in repo?
How well will that work when original commits are reordered or the history is not linear in some way. Basically when it's not easy to do an incremental change?
The use case described implies that the new commits being uploaded have a parent commit that already exists in this repository. I'll ask OSTree devs what should happen if the parent commits are missing.
The parent commit does not have to be in the repository for the upload to succeed.
- Description updated (diff)
- Parent issue set to #8924
- Related to Story #8918: As a user, I can create a new repository by uploading an archive with OSTree commits added
This is almost implemented in the PR referenced in the issue https://pulp.plan.io/issues/8918.
In addition to that PR, we will need to associate a parent commit with its child when passed via the API. If there does not exist a relation between a commit and its parent (i.e., a user passed invalid data), an error should be raised. But, if no parent commit is specified, Pulp will simply add a new commit and will update the ref in a new repository version (this part already works in https://pulp.plan.io/issues/8918).
lmjachky wrote:
This is almost implemented in the PR referenced in the issue https://pulp.plan.io/issues/8918.
In addition to that PR, we will need to associate a parent commit with its child when passed via the API. If there does not exist a relation between a commit and its parent (i.e., a user passed invalid data), an error should be raised. But, if no parent commit is specified, Pulp will simply add a new commit and will update the ref in a new repository version (this part already works in https://pulp.plan.io/issues/8918).
This behavior sounds right to me.
How is the user specifying a parent commit? Is it part of the archive or is it a parameter that is provided in addition to the tarball?
- Status changed from NEW to ASSIGNED
- Assignee set to lmjachky
- Sprint set to Sprint 104
- Status changed from ASSIGNED to POST
- Status changed from POST to MODIFIED
- % Done changed from 0 to 100
Also available in: Atom
PDF
Add support for adding commits to a repository
In this commit, refshead was renamed to ref. Also, before this commit, we referred to adding commits as uploading. This was conceptually wrong since we were not uploading commits, but rather importing them from artifacts already uploaded to Pulp.
closes #8919