Chapter 9. Managing content templates


A content template is a set of repository snapshots you have selected to ensure your systems only have access to specific package versions. Using the content templates, you can establish date-based patch baselines for your systems and perform updates of your systems using yum or dnf.

9.1. Creating a content template

You can create a content template to ensure your system retains access to specific package versions.

Prerequisites

  • You have a RHEL subscription.
  • You have Organization Administrator or Content Template administrator permissions.
  • The custom repositories that you want to include in the template have snapshots.

Procedure

  1. Access Hybrid Cloud Console.
  2. Go to Services Red Hat Enterprise Linux Content Templates.
  3. Click Add content template. The Create content template wizard opens.
  4. In the Content section complete the following:

    1. On the Define content page, select the architecture and the OS version of your system. Click Next.
    2. On the Red Hat repositories page, select repositories you want to include in the template. Click Next.
    3. On the Custom Repositories page, select repositories you want to include in the template. Click Next.

      Note, only repositories with enabled snapshot functionality are displayed in the list of repositories.

  5. On the Set snapshot date page, select:

    Use latest content
    To use the latest content from the repository during image building. Click Next.
    Use a snapshot

    To use a repository snapshot. Select the date and then click Next.

    Note, if your repository does not have the required snapshot, it chooses the earliest possible snapshot to the date of your choice.

  6. On the Detail page, provide a name for your template. Optionally, provide a description of your template. Click Next.
  7. On the Review page, verify the details about the template and click Create template and add to systems. Assign template to systems opens.

    Optional: Click Create template only if you want to assign this template to systems later.

  8. Select all the systems you want to assign the template to and click Assign.

    This change updates the /etc/yum.repos.d/redhat.repo file on the selected systems. All changes affect your systems every four hours. If you want this change to affect your systems immediately, you must manually refresh subscription-manager on the selected system:

    # subscription-manager refresh

Verification

  1. Go to Services Red Hat Enterprise Linux Content Templates and verify your template is added to the list of templates.
  2. On your system, check the /etc/yum.repos.d/redhat.repo file contains https://cert.console.redhat.com.

Next steps

  • You can edit your content template, assign your template to systems, and delete it. For more details, see Editing content template.

9.2. Editing a content template

You can modify the snapshot date for your content template, assign your content template to more systems, and delete your content template.

Prerequisites

  • You have a RHEL subscription.
  • You have Organization Administrator or Content Template administrator permissions.
  • The custom repositories that you want to include in the template have snapshots.

Procedure

  1. Access Hybrid Cloud Console.
  2. Go to Services Red Hat Enterprise Linux Content Templates.
  3. Select the content template you want to edit and choose an action from the following options:

    • To edit repositories, snapshot date, and the name of your content template, go to Actions Edit and follow the Edit content template wizard.

      Note, if you edit a snapshot date for the template, it sets a new baseline for patching, and the systems start using the new snapshot.

    • To assign this template to more systems, go to Systems, click Assign template to systems and select the systems you want to assign this template to. Click Assign.
    • To delete the content template, go to Actions Delete.
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.

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.

© 2024 Red Hat, Inc.