-
Notifications
You must be signed in to change notification settings - Fork 54
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
rhel9: systemd service to create mountpoints for filesystem customizations for edge images #399
rhel9: systemd service to create mountpoints for filesystem customizations for edge images #399
Conversation
this is a silly cross-check from me, have we made sure that data is properly persisted within these mountpoints? |
I tested this out, data persists. |
@henrywang When this is added to composer, can we get a test for this added? We will need to add custom mountpoints to an edge image and then upgrade it, so I think it can be included in the existing test scripts. |
da244b5
to
48e5ed9
Compare
48e5ed9
to
bc4e8bc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes that I requested were added, LGTM
823900d
to
925468b
Compare
The CI failure is expected as the, the unit condition fails on first boot, it runs when there is an upgrade when the mount-points gets deleted. Will be doing some manual testing on "edge-ami" to confirm the functionality. |
9775def
to
5fed2b5
Compare
5fed2b5
to
0244275
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm OK with this as is, we can't do better as far as I know without reworking how blueprints work for builds.
(We need to discuss a couple of things about this PR, please do not merge yet) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the fix.
Unfortunately, I'm not in favor of using *fsnode.File
for this purpose. I propose to extend https://github.com/osbuild/osbuild/blob/main/stages/org.osbuild.systemd.unit and use it instead.
The rest looks OK to me.
In general, *fsnode.File
is not intended as a workaround for not creating / enhancing osbuild stages, unless the problem is a special / corner case.
See also ostreedev/ostree#2681 |
79f3af0
to
286eb7b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good in general. The git history needs some work though.
The first commit adds a config to the config-map (ostree-filesystem-customizations-installer.json
) that doesn't get added until the fourth commit.
Also the commit message in the fourth commit doesn't match the patch anymore. It mentions disabling the edge-ami boot test which it doesn't do.
a6d35ee
to
9576748
Compare
the commit history is cleaned up to make it in accordance to the changes made.
28116f7
to
b173fab
Compare
b173fab
to
22bfa38
Compare
blocked on : osbuild/osbuild#1666 |
22bfa38
to
27265a1
Compare
rhel version fixed and added service description
Filesystem customizations is enabled for edge-raw-image, edge-ami,edge-vsphere, edge-simplified-installer relevent testing config is added to run in CI Signed-off-by: Sayan Paul <[email protected]>
Create systemd unit using the system-unit-create stage This new stage adds the ability to create a systemd service unit file. It provides customization to choose the unit-type and unit-path, defaults to '/usr/lib/systemd/system/' Filename is validated using the same rules as specified by systemd.unit(5) and they must contain the '.service' suffix (other types of unit files are not supported). config accepts sections: `Unit`, `Service`, `Install` and each section accepts list of options that is in accordance to systemd.service documentation. Relavent testing is also added. Signed-off-by: Sayan Paul <[email protected]>
Hooked up the create-unit-stage to add create-mountpoint.service to ostree deployment. Automatically add and enable osbuild-create-mountpoint.service whenever user adds filesystem customizationi, to ensure that the mountpoints are available post rpm-ostree upgrade. Signed-off-by: Sayan Paul <[email protected]>
Signed-off-by: Sayan Paul <[email protected]>
27265a1
to
56c05f3
Compare
Filesystem customization mountpoints does not persists any upgrade due to the property of ostree which only persists data on /var and /etc. This feature will ingest the filesystem customization and create a unit file which can create the required mountpoints if it doesnot exist.