-
Notifications
You must be signed in to change notification settings - Fork 34
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
README.md: Document how to create a new CI image #6182
base: main
Are you sure you want to change the base?
Conversation
jelly
commented
Apr 5, 2024
•
edited
Loading
edited
- document how to build a package for a new image.
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.
Thanks for starting this! This needs some grammar/interpunction polish too, but let's first collect all the info which we want to add here.
@@ -43,6 +43,29 @@ For running and debugging the images: | |||
overlay in test/images/ instead. | |||
- `vm-reset`: Remove all overlays from test/images/ | |||
|
|||
### Creating a new image | |||
|
|||
Creating a new image from scratch requires a bootstrap and a setup script, |
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.
Technically the setup script is optional
called `tux` and we run `./image-create -v tux` to create this image we | ||
expect two scripts: | ||
|
||
- `tux.bootstrap`: The bootstrap script downloads the latest available cloud image (qcow2) |
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.
While most of our images start with a cloud image, some don't (cirros, bootc, rhel-7.9, rhel4edge). Perhaps
The bootstrap script has to produce a bootable qcow2 image file, e.g. by downloading a cloud image or invoking some image build service.
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.
Ah! TIL
Cockpit team member to create a copy of the PR and follow this workflow. | ||
|
||
For the initial PR it is recommended to add the new image to the `_manual` | ||
testmap of `starter-kit` to proof the created image is functional. |
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 think this should be expanded to explain how to boot-test the image, with ./vm-run
, trying to log in via SSH as root
and admin
, testing sudo on the latter. And then trying starter-kit against it locally to ensure it has a functioning package build environment.
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.
Trying starter-kit requires a script to build packages right? We should also document that ideally and then vm-customize
.
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.
Hm, right, if it's not rpm. We don't even support .deb there yet. cockpit-ostree has an alternative approach which directly copies dist/ into the VM's /usr/local/share/ -- that is also a good start for a new distro that avoid blocking on packaging as the first step.