Chapter 4. Using the command-line assistant component functions in Image Mode for RHEL


You can use the command-line assistant component functions in Image Mode for RHEL during container builds and at runtime. The assistant performs system tasks while maintaining read-only file system security on x86_64 and aarch64 architectures.

Prerequisites

Procedure

  1. Create a Containerfile:

    $ cat Containerfile
    FROM registry.redhat.io/rhel10/rhel-bootc:latest
    RUN <<EORUN
    set -euxo pipefail
    dnf install -y command-line-assistant
    dnf clean all
    rm -rf /var/cache/dnf/
    bootc container lint
    EORUN
  2. Build the <image> image by using Containerfile in the current directory:

    $ podman build -t quay.io/<namespace>/<image>:<tag> .
  3. Build a disk image from the container image. The following example creates a QCOW2 image:

    $ sudo podman run \
        --rm \
        -it \
        --privileged \
        --pull=newer \
        --security-opt label=type:unconfined_t \
        -v ./config.toml:/config.toml:ro \
        -v ./output:/output \
        -v /var/lib/containers/storage:/var/lib/containers/storage \
        registry.redhat.io/rhel10/bootc-image-builder:latest \
        --type qcow2 \
        --config /config.toml \
        quay.io/<namespace>/<image>:<tag>
    • <namespace>: your container registry namespace.
    • <image>: your image name.
    • <tag>: your image tag, for example, latest.
  4. Boot a machine with the QCOW2 disk image. For instructions, see Deploying a container image by using KVM with a QCOW2 disk image.

Verification

  • Verify that the installation works by running the command-line assistant. For example:

    $ c "How to deploy a QCOW2 disk image?"

    The output looks similar to the following example:

    +*+ Asking RHEL Lightspeed
    
    To deploy a QCOW2 disk image....
Red Hat logoGithubredditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust. Explore our recent updates.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

Theme

© 2026 Red Hat
Back to top