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

[RFC] packagesets: add basic imagetype yaml to merge pkgSets (non-symetric) #1296

Closed
wants to merge 1 commit into from

Conversation

mvo5
Copy link
Contributor

@mvo5 mvo5 commented Mar 6, 2025

[draft as this is one possible way of doing it, all fedora package_sets.yaml needs converting, not a huge fan because it is not symmetrical but it is very simple. maybe different naming would make it feel less asymetric. alternative version of https://github.com/https://github.com//pull/1294 and https://github.com//pull/1295]

This commit adds a basic imagetype yaml to support merging of package sets This is a useful feature so that we can e.g. avoid duplicating the cloud_base or anaconda package sets.

It works by adding a new toplevel "image_types" in the package_sets.yaml.

It allows us to write:

image_types:
 qcow2:
  package_sets:
   - cloud_base_pkgset
   - qcow2_pkgset

package_sets:
  cloud_base_pkgset:
    include: [foo]
    exclude: [bar]
  qcow2_pkgset:
    include: [qemu-guest-agent]

The downside of this approach is that it is nice to read but not symetrical, i.e. one cannot just include the pkgset verbatim in an image_type, it always needs to be defined inside the "package_sets" key. It also uses the same "package_sets" name for two different things which is also slightly not nice.

This commit adds a basic imagetype yaml to support merging
of package sets  This is a useful feature so that we can e.g.
avoid duplicating the `cloud_base` or `anaconda` package sets.

It works by adding a new toplevel "image_types" in the
package_sets.yaml.

It allows us to write:
```yaml
image_types:
 qcow2:
  package_sets:
   - cloud_base_pkgset
   - qcow2_pkgset

package_sets:
  cloud_base_pkgset:
    include: [foo]
    exclude: [bar]
  qcow2_pkgset:
    include: ["qemu-guest-agent"]
```
The downside of this approach is that it is nice to read but not
symetrical, i.e. one cannot just include the pkgset verbatim in
an `image_type`, it always needs to be defined inside the
"package_sets" key. It also uses the same "package_sets" name
for two different things which is also slightly not nice.
@mvo5 mvo5 changed the title packagesets: add basic imagetype yaml to merge pkgSets [RFC] packagesets: add basic imagetype yaml to merge pkgSets Mar 6, 2025
@supakeen
Copy link
Member

supakeen commented Mar 6, 2025

Stylistically I prefer #1295, it also seems like that one would more easily map on people who have knowledge of YAML as opposed to this one.

@mvo5 mvo5 changed the title [RFC] packagesets: add basic imagetype yaml to merge pkgSets [RFC] packagesets: add basic imagetype yaml to merge pkgSets (non-symetric) Mar 7, 2025
@mvo5
Copy link
Contributor Author

mvo5 commented Mar 10, 2025

Closing this in favor of #1298

@mvo5 mvo5 closed this Mar 10, 2025
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.

2 participants