8.2. Creating a pre-hardened image with RHEL image builder


RHEL image builder on-premise supports the OpenSCAP integration. This integration enables the production of pre-hardened RHEL images.

By setting up a blueprint, you can perform the following actions:

  • Create images that are pre-hardened and compliant with a specific profile
  • Deploy the pre-hardened images in a VM, or a bare-metal environment, for example.

Prerequisites

  • You are logged in as the root user or a user who is a member of the weldr group.
  • The openscap and scap-security-guide packages are installed.

Procedure

  1. Create a hardening blueprint in the TOML format, using the OpenSCAP tool and scap-security-guide content, and modify it if necessary:

    # oscap xccdf generate fix --profile=<profileID> --fix-type=<blueprint> /usr/share/xml/scap/ssg/content/ssg-rhel10-ds.xml > cis.toml

    Replace <profileID> with the profile ID that the system should comply with, for example, cis.

  2. Start the build of hardened image:

    # image-builder build <image_type> --blueprint <blueprint_name>

    Replace <image_type> with any image type, for example, qcow2.

    After the image build is ready, you can use your pre-hardened image on your deployments. See Creating a virtual machine from a KVM guest image.

Verification

After you deploy your pre-hardened image, you can perform a configuration compliance scan to verify that the image is aligned with the selected security profile.

重要

Performing a configuration compliance scanning does not guarantee the system is compliant. For more information, see Configuration compliance scanning.

Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。 了解我们当前的更新.

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

Theme

© 2026 Red Hat
返回顶部