Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: osbuild/images
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.123.0
Choose a base ref
...
head repository: osbuild/images
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v0.124.0
Choose a head ref

Commits on Mar 10, 2025

  1. osbuild: add Swap section for systemd.unit.create stage options

    Add a Swap section and support for .swap systemd units.
    This commit also adds a separate filename regex for unit files that
    differs from the one we have for general files.  Specifically, it allows
    for backslashes, which we will need to create .swap unit files.  The
    filenames for these units must be the escaped path to the device or file
    they control, which can contain escape characters (e.g. \x2d for
    escaping a dash).
    
    The Service and Install sections are now marked 'omitempty' since they
    can be omitted (depending on the type of the unit).
    
    See also systemd.swap(5)
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    fb88b71 View commit details
  2. osbuild: generate systemd mount stages from partition table

    GenSystemdMountStages() generates systemd .mount and .swap stages based
    on a partition table.  This is an alternative to generating an fstab
    stage for the mountpoints.
    
    The generator creates one systemd.unit.create stage for each mountpoint
    (and swap) and an extra stage that enables all the new units after they
    are written.
    
    vfat volume IDs are discovered by matching against a new regular
    expression defined in the `mkfs_fat_stage.go` file.  This is needed
    because non-UUID identifiers are not lowercased in /dev/disk/by-uuid.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    288f7c6 View commit details
  3. osbuild: test GenSystemdMountStages()

    Test GenSystemdMountStages() using test partition tables from testdisk.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    7b19311 View commit details
  4. manifest: add option to pipelines for generating mount units

    Add a boolean to each pipeline that generates a filesystem description
    (i.e. creates an org.osbuild.fstab stage), which when enabled will
    create systemd mount units instead of writing the static filesystem
    description to /etc/fstab.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    bcd56fb View commit details
  5. manifest: test pipeline generation with fstab or mount units

    Test all pipelines that support filesystem configuration switching
    between /etc/fstab and systemd .mount units.  These are:
    - OS
    - OSTreeDeployment
    - RawBootcImage
    
    This commit also includes some test restructuring.
    - The OS pipeline tests have been moved to manifest_test, external to
      the manifest package.
    - Functions that are needed for both internal and external tests are
      defined and exported from the export_test.go file in the manifest
      package.  We should move all tests to the external manifest_test
      package eventually.
    
    The testing is a little inconsistent now between different kinds of
    pipelines.  Some run serializeStart() and serialize() in the same
    exported function, and others (bootc) export both.  These should be
    made consistent, but for now it's okay.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    5c8f12f View commit details
  6. distro: support enabling mount units through ImageConfig

    Add a flag for enabling mount units on ImageConfig and copy the value to
    the OSCustomizations (for rpm-based disk images) and the
    OSTreeDploymentCustomizations.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    e9e8dd6 View commit details
  7. Copy the full SHA
    43f1a32 View commit details
  8. Copy the full SHA
    ef689f7 View commit details
  9. test: add Fedora 42 and 43 repositories

    Add repos for branched (42) and rawhide (43) to start testing.
    Generate the new gitlab config.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    d285ec6 View commit details
  10. distro: define ImageType.KernelOptions as a slice

    Make KernelOptions a string slice where each element is a separate
    option.  This makes it easier to manipulate each option individually,
    which we will need later to modify default options when using mount
    units.
    
    The options are defined in functions instead of global vars to avoid
    modifying the static values.
    
    This commit has a non-functional effect on manifest generation:
    Edge and IoT images that use org.osbuild.ostree.deploy stage now define
    each option as a separate element in the `kernel_opts` slice.
    Previously, it would be a mix of space-separated multi-option strings
    and individual ones.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    2f537bd View commit details
  11. manifest,osbuild: handle all fs-related kargs in GenImageKernelOptions()

    Move the root UUID discovery from the OS pipeline into the
    GenImageKernelOptions() function.  Previously this was done in the
    prependKernelCmdlineStage().  That function now simply generates the
    stage and adds it to the top of the pipeline and doesn't do any
    discovery on its own.
    
    The following commits will add more filesystem-related kernel
    command-line argument handling to the osbuild function.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    5801fc5 View commit details
  12. osbuild: extract test UUID collection to function

    To be reused in new tests.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    ace4a93 View commit details
  13. manifest: add mount.usr options to kernel cmdline when necessary

    When /usr is on a separate mountpoint and we're not writing an
    /etc/fstab, the filesystem information should be included in the kernel
    cmdline arguments for autodiscovery to work.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    ab1a094 View commit details
  14. manifest: mount root device rw and set rootflags when using mount units

    The systemd-remount-fs service reads mount options from /etc/fstab for
    the root partition (and /usr, if separate).  If there is no /etc/fstab,
    the fs is not remounted, so a read-only mount will stay read-only on
    boot.
    
    Switch the "ro" command line argument to "rw" if we're not writing an
    /etc/fstab file.
    Also, add the root mount options as rootflags when they are not just
    "defaults".
    
    Add tests for the new functionality in GenImageKernelOptions().
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    c5bf3fc View commit details
  15. distro/fedora: use mount units for minimal-raw on F43+

    Starting from Fedora 43, use mount units instead of writing /etc/fstab
    for the minimal-raw image type.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    72cec81 View commit details
  16. distro: support setting 'no-fstab' in experimental flags

    Setting IMAGE_BUILDER_EXPERIMENTAL="no-fstab" will enable mount units
    without /etc/fstab for any image type.
    achilleas-k authored and supakeen committed Mar 10, 2025
    Copy the full SHA
    3d51839 View commit details
  17. blueprint: rename local 'append' variable

    Rename it to avoid shadowing the built-in function.
    achilleas-k authored and thozza committed Mar 10, 2025
    Copy the full SHA
    5272b73 View commit details
  18. Copy the full SHA
    770bb17 View commit details
  19. manifest: don't write locale when unset

    Don't write out the locale file to disk when it is unset in the
    OSCustomizations.
    
    Signed-off-by: Simon de Vlieger <supakeen@redhat.com>
    supakeen authored and achilleas-k committed Mar 10, 2025
    Copy the full SHA
    57731aa View commit details
  20. fedora: move hostname to image config

    Moves the hostname to the image config.
    
    Signed-off-by: Simon de Vlieger <supakeen@redhat.com>
    supakeen authored and achilleas-k committed Mar 10, 2025
    Copy the full SHA
    6039b39 View commit details
  21. manifest: don't write timezone when no timezone

    Signed-off-by: Simon de Vlieger <supakeen@redhat.com>
    supakeen authored and achilleas-k committed Mar 10, 2025
    Copy the full SHA
    c75393d View commit details
  22. test: hostname customization

    Add a small test to see if hostname stages are added or not.
    
    Signed-off-by: Simon de Vlieger <supakeen@redhat.com>
    supakeen authored and achilleas-k committed Mar 10, 2025
    Copy the full SHA
    14029c0 View commit details

Commits on Mar 11, 2025

  1. tools: add new "gen-manifests-diff" tool

    gen-manifests-diff is a helper to diff the generated manifests
    against what the current "main" of the images library would do.
    
    Alternatively a revision can be given as the first argument
    and with that the diff is calculated against that. All images
    types and architectures are used by default. It is still
    very fast (typically 3s).
    
    Example output:
    ```
    calculating diff against d285ec6
    found differences between /tmp/tmpbjhime7p/new and reference manifests:
    diff -uNr /tmp/tmpbjhime7p/ref/centos_9-aarch64-edge_ami-edge_ostree_pull_user.json /tmp/tmpbjhime7p/new/centos_9-aarch64-edge_ami-edge_ostree_pull_user.json
    --- /tmp/tmpbjhime7p/ref/centos_9-aarch64-edge_ami-edge_ostree_pull_user.json   2025-03-10 20:55:20.736477268 +0100
    +++ /tmp/tmpbjhime7p/new/centos_9-aarch64-edge_ami-edge_ostree_pull_user.json   2025-03-10 20:55:22.294453956 +0100
    @@ -161,7 +161,13 @@
                 },
                 "kernel_opts": [
                   "luks.uuid=e3eb0343-83b0-441c-a8aa-6a715afc1d39",
    -              "console=tty0 console=ttyS0,115200n8 net.ifnames=0 nvme_core.io_timeout=4294967295 modprobe.blacklist=vc4 rw coreos.no_persist_ip",
    +              "console=tty0",
    +              "console=ttyS0,115200n8",
    +              "net.ifnames=0",
    +              "nvme_core.io_timeout=4294967295",
    +              "modprobe.blacklist=vc4",
    +              "rw",
    +              "coreos.no_persist_ip",
                   "ignition.platform.id=metal",
                   "$ignition_firstboot"
                 ]
    ...
    ```
    
    This is (hopefully) the uncontroversial part of
    #1307
    and already useful when checking that a yamlification (or other
    change) is not resulting in any regressions. Also useful to see
    if a change results in the expected change(s).
    mvo5 authored and bcl committed Mar 11, 2025
    Copy the full SHA
    902e976 View commit details
  2. tools: fix ppc64le typo

    Signed-off-by: Simon de Vlieger <supakeen@redhat.com>
    supakeen authored and thozza committed Mar 11, 2025
    Copy the full SHA
    48252e2 View commit details

Commits on Mar 12, 2025

  1. gen-manifests: de-duplicate packages on the depsolve level

    This is a better version of #1312
    that moves the de-duplication of packages into the package depsolver
    of gen-manifests. This is similar to how osbuild-depsolve-dnf works
    that also will present a de-duplicated result.
    
    Thanks to thozza for the suggestion to do it this way.
    mvo5 authored and achilleas-k committed Mar 12, 2025
    Copy the full SHA
    7b03276 View commit details
  2. osbuild: Add org.osbuild.grub2.iso.legacy stage

    This is used to setup the configuration file for an ISO that boots with
    grub2 and BIOS.
    bcl committed Mar 12, 2025
    Copy the full SHA
    88e06b9 View commit details
  3. osbuild: Add iso9660 support to grub2_inst_stage

    The grub2 BIOS iso needs an eltorito.img built by grub2-mkimage. This is
    created when location isn't passed to org.osbuild.grub2.inst and the
    filesystem is set to iso9660.
    
    In order to support this some of the fields become optional, and iso9660
    is added to the list of allowed filesystems.
    bcl committed Mar 12, 2025
    Copy the full SHA
    54a81f9 View commit details
  4. iso: Add support for selecting the type of BIOS iso

    This adds an ISOBootType enum that replaces the ISOLinux bool in order
    to control what type of boot iso is created:
     - UEFI only using grub2
     - syslinux on BIOS and grub2 UEFI
     - grub2 for both BIOS and UEFI
    
    It also adds the Grub2MBR option to the xorrisofs stage.  Setting this
    to the path of the grub2 hybrid boot image
    (eg./usr/lib/grub/i386-pc/boot_hybrid.img) will cause the created ISO to
    use grub2 to boot on BIOS systems.
    
    This overrides the presence of the ISOHybridPath and does not use
    syslinux.
    
    In order to support this it does require that the grub2-pc-modules
    package is installed.
    
    This also adds a stage using Grub2InstStage to create the eltorito.img
    needed by grub2.
    bcl committed Mar 12, 2025
    Copy the full SHA
    cd5b1f5 View commit details
  5. Copy the full SHA
    71022e8 View commit details
  6. image: Add ISOBoot to AnacondaLiveInstaller

    On Fedora select Grub2ISOBoot when building on x86, otherwise the ISO is
    UEFI only.
    bcl committed Mar 12, 2025
    Copy the full SHA
    dbb12ac View commit details
  7. image: Add ISOBoot to NewAnacondaOSTreeInstaller

    On Fedora select Grub2ISOBoot when building on x86, otherwise the ISO is
    UEFI only.
    
    On RHEL x86 builds use Grub2ISOBoot for RHEL10, SyslinuxISOBoot for
    other versions and on non-x86 use UEFI only.
    bcl committed Mar 12, 2025
    Copy the full SHA
    2cd1655 View commit details
  8. image: Add ISOBoot to NewAnacondaTarInstaller

    On Fedora select Grub2ISOBoot when building on x86, otherwise the ISO is
    UEFI only.
    
    On RHEL x86 builds use Grub2ISOBoot for RHEL10, SyslinuxISOBoot for
    other versions and on non-x86 use UEFI only.
    bcl committed Mar 12, 2025
    Copy the full SHA
    84dc088 View commit details
  9. image: Use ISOBoot in ostree simplified

    OSTree simplified always uses SyslinuxISOBoot.
    bcl committed Mar 12, 2025
    Copy the full SHA
    e0dfeb6 View commit details
  10. tools: add note/warning about limits of gen-manifests-diff

    As suggested by thozza this adds a note about the limits of
    `gen-manifests-diff`.
    
    Thanks to thozza.
    mvo5 authored and supakeen committed Mar 12, 2025
    Copy the full SHA
    42fc835 View commit details

Commits on Mar 13, 2025

  1. distro: refactor packageSetFunc() to return an error

    This commit tweaks the packageSetFunc() to return an error. With
    that we can avoid `panics()` and instead just pass the error up.
    
    Thanks to Brian for suggesting to clean this up.
    mvo5 authored and supakeen committed Mar 13, 2025
    Copy the full SHA
    eb8b7bf View commit details
  2. packagesets: introduce IMAGE_BUILDER_EXPERIMENTAL=yamldir=...

    This commit adds a new `IMAGE_BUILDER_EXPERIMENTAL=yamldir=...`
    experimental flag to force setting the datadir for the yaml
    directory to override e.g. packagesets.
    
    Ideally we would pass this all the way down the stack via a
    search path but this will require a bunch of more refactoring.
    So to give people the ability to tweak packagesets today, start
    here.
    mvo5 authored and ondrejbudai committed Mar 13, 2025
    Copy the full SHA
    86cc1a3 View commit details
  3. README: mention new IMAGE_BUILDER_EXPERIMENTAL=yamldir

    Add a short explaination about local development for the yaml
    definitions.
    mvo5 authored and ondrejbudai committed Mar 13, 2025
    Copy the full SHA
    93da234 View commit details
  4. Copy the full SHA
    6a5695d View commit details
  5. packagesets: add basic imagetype yaml to merge pkgSets

    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 new toplevels "image_types" in the
    package_sets.yaml and then using anchors/refs to refer to
    them in the image_type yaml. To allow sharing yaml that is
    not part of an image_type it also introduces a top-level
    `.common` that can have `any` yaml in it.
    
    It allows us to write:
    ```yaml
    .common:
      base: &base_pkgset
        include: [from-base-inc]
        exclude: [from-base-exc]
        condition:
          distro_name:
            test-distro:
              include: [from-base-condition-inc]
              exclude: [from-base-condition-exc]
    
    image_types:
      other_type:
        package_sets:
          - &other_type_pkgset
            include: [from-other-type-inc]
            exclude: [from-other-type-exc]
      test_type:
        package_sets:
          - *base_pkgset
          - *other_type_pkgset
          - include: [from-type-inc]
            exclude: [from-type-exc]
            condition:
              distro_name:
                test-distro:
                  include: [from-condition-inc]
                  exclude: [from-condition-exc]
    ```
    The downside of this approach is that:
    1. it requires the anchor to be there before the ref, which can
       be confusing (we could solve this later via includes)
    2. if the anchor is forgotten the error becomes very obscure
    3. its a bit "hardcore" yaml
    
    The upside is that it is very symetrical and actually feels quite
    nice.
    mvo5 authored and ondrejbudai committed Mar 13, 2025
    Copy the full SHA
    d91c5c7 View commit details
  6. blueprint: support specifying partition types

    Add support for specifying the partition type for disk customizations.
    This is the type of the partition, specified as a GUID (UUID) for GPT
    partitions (see for example the Discoverable Partitions Specification
    [1]) or a 2-digit hex number for DOS partitions [2].
    
    Ideally we would call this parameter 'type' but we already use that for
    defining 'plain', 'lvm', or 'btrfs'.
    
    The validator checks the format of the type based on the partition table
    type if set, otherwise checks for both because the fallback type is
    unknown at the time.
    
    [1] https://uapi-group.org/specifications/specs/discoverable_partitions_specification/
    [2] https://tldp.org/HOWTO/Partition-Mass-Storage-Definitions-Naming-HOWTO/x190.html
    ondrejbudai authored and achilleas-k committed Mar 13, 2025
    Copy the full SHA
    b27cc11 View commit details
  7. disk: use custom partition type (part_type) when making partition table

    Read the custom part type if it's set, otherwise infer it from the
    mountpoint and partition table type.
    
    At this stage, in NewCustomPartitionTable(), we know the partition table
    type, so we can verify the partition type ID again with more strictness.
    
    To avoid duplicating the validator, we use the partition method again.
    It would have been nicer to have this kind of validation in the disk
    package instead of the blueprint, but that would create an import cycle.
    ondrejbudai authored and achilleas-k committed Mar 13, 2025
    Copy the full SHA
    0a4d17f View commit details
  8. docs: document gen-manifests-diff workflow

    Tiny addition to the doc to document the basic usage of
    `gen-manifests-diff`.
    mvo5 authored and thozza committed Mar 13, 2025
    Copy the full SHA
    f34f76d View commit details

Commits on Mar 14, 2025

  1. devcontainer: rename

    Signed-off-by: kksat <22549266+kksat@users.noreply.github.com>
    kksat authored and supakeen committed Mar 14, 2025
    Copy the full SHA
    d35f9a2 View commit details
  2. devcontainer: update Dockerfile

    install project dependencies
    use latest fedora as base
    Signed-off-by: kksat <22549266+kksat@users.noreply.github.com>
    kksat authored and supakeen committed Mar 14, 2025
    Copy the full SHA
    ec6acd7 View commit details
  3. devcontainer: add command to download all required go packages

    Signed-off-by: kksat <22549266+kksat@users.noreply.github.com>
    kksat authored and supakeen committed Mar 14, 2025
    Copy the full SHA
    a52fe88 View commit details
  4. common: add common.Must() helper to shortcut NewT() (T, error)

    The new `common.Must()` helper can be used in e.g. tests that
    want a short way of writing `NewFoo() (Foo, error)` or
    `LoadBar() (Bar, error)`, e.g.
    ```go
    map[string]rhel.PackageSetFunc{
        rhel.OSPkgsKey: func(t *rhel.ImageType) rpmmd.PackageSet {
    	return common.Must(packagesets.Load(t, "bare-metal", nil))
        },
    }
    ```
    mvo5 authored and achilleas-k committed Mar 14, 2025
    Copy the full SHA
    8d747b3 View commit details
  5. distro: make yamlloader deal with different dir layouts

    This commit makes the yaml loader deal with different layout
    for the yaml directories and also deals with the fact that
    go:embed does not support symlinks.
    
    This is (hopefully) a temporary measure, I expect that eventually
    there will be a `distros.yaml` or similar file that describes
    the various distros supported and some details (like their data
    dir).
    mvo5 authored and achilleas-k committed Mar 14, 2025
    Copy the full SHA
    bf5f8fb View commit details
  6. rhel10: replace all package sets with packagesets.Load()

    This replaces the rhel10 package sets with yaml files. Note that
    it uses `common.Must` as a stopgap for now to bridge between
    the packagesets.Load() helper and the rhel PackageSetFunc. This
    will just go away once all rhel versions are converted.
    mvo5 authored and achilleas-k committed Mar 14, 2025
    Copy the full SHA
    29bc1eb View commit details
  7. Copy the full SHA
    c405336 View commit details
  8. distro: add cloud init WSL image config

    This mirrors the Ubuntu images in the MS store. The WSL datasource looks
    for userdata on the Windows host.
    croissanne authored and achilleas-k committed Mar 14, 2025
    Copy the full SHA
    009677f View commit details
Loading