Skip to content

Embedding RPM application packages in the root partition

You can embed RPM packages for critical application workloads either from local storage or from a remote repository.

Embedding RPM packages from local storage into the AutoSD image

Embed your RPM-packaged application in the AutoSD image with the automotive-image-builder tool. This tool leverages OSBuild to pull your application from your RPM package repository at build time, automatically resolving and installing the dependencies for your RPM package.

You can view a complete example manifest for user and group configuration in the demos/rpm_local/rpm_local.aib.yml file.

Prerequisites

  • An RPM package auto-apps in an RPM repository /var/tmp/my_repo

Procedure

  1. Create a new .aib.yml automotive image builder manifest file to contain the custom configuration for your AutoSD image:

    touch rpm_local.aib.yml
    
  2. In rpm_local.aib.yml, name your manifest and define one or more RPM repositories in a content stage:

    automotive image builder manifest
    name: rpm_local
    
    content:
      repos:
        - id: epel
          baseurl: https://dl.fedoraproject.org/pub/epel/9/Everything/$arch/
        - id: auto-apps
          baseurl: file:///var/tmp/my_repo
    
  3. Define one or more RPM packages that you want to install from these repositories. For example, include the auto-apps package:

    automotive image builder manifest
      rpms:
        - auto-apps
    

When you build your operating system (OS) image, OSBuild installs the auto-apps RPM in the default location in your OS image. This default location is for critical applications. For more information about installing RPM packages in the QM partition of your OS image, see Embedding RPM application packages in the QM partition.

Next steps

  • Now that you included your RPM package repository and RPM package application in a new custom automotive image builder manifest, you can build your AutoSD image. For more information, see Building an AutoSD image.
  • Alternatively, you can continue customizing your image. For more information, see Containerizing applications.

Additional resources

Embedding RPM packages from remote repositories into the AutoSD image

Configure your manifest file to embed RPM packages from the remote repository of a Linux distribution. The automotive-image-builder tool uses this manifest to automatically resolve and embed your remote applications and their dependencies into your AutoSD image at build time.

You can view a complete example manifest for user and group configuration in the demos/rpm_remote/rpm_remote.aib.yml file.

Prerequisites

  • One or more base URLs for any content repository that has application RPM packages

Procedure

  1. Open the manifest file you created in Embedding RPM packages from local storage into the AutoSD image, or create a new automotive image builder manifest file to contain your custom configuration for your AutoSD image:

    touch rpm_remote.aib.yml
    
  2. In rpm_remote.aib.yml, name your manifest and define the RPM packages that you want to install in a content section:

    automotive image builder manifest
    name: rpm_remote
    
    content:
      rpms:
        - vim-enhanced
        - wget
    
  3. Optional. If you want to enable a custom RPM repository, add the definition to the content section. For example, enable the Extra Packages for Enterprise Linux (epel) repository:

    automotive image builder manifest
    content:
      repos:
        - id: epel
          baseurl: https://dl.fedoraproject.org/pub/epel/9/Everything/$arch/
    

Next steps


© Red Hat