2.7. 入力ファイルを使用した新しい Red Hat コンテンツリポジトリーの追加


Red Hat Update Infrastructure 4.2 以降では、設定された YAML 入力ファイルを使用してカスタムリポジトリーを追加できます。YAML ファイルのテンプレート例は、RHUA ノードの /usr/share/rhui-tools/examples/repo_add_by_file.yaml ディレクトリーにあります。

この機能はコマンドラインインターフェイス (CLI) でのみ利用できます。

前提条件

  • RHUA ノードへの root のアクセス権がある。

手順

  1. RHUA ノードで、以下の形式で YAML 入力ファイルを作成します。

    # cat /root/example.yaml
    name: Example_YAML_File
    repo_ids:
        - rhel-8-for-x86_64-baseos-eus-rhui-rpms-8.1
        - rhel-8-for-x86_64-baseos-eus-rhui-rpms-8.2
        - rhel-8-for-x86_64-baseos-eus-rhui-rpms-8.4
        - rhel-8-for-x86_64-baseos-eus-rhui-rpms-8.6
  2. rhui-manager ユーティリティーを使用して、入力ファイルに一覧表示されているリポジトリーを追加します。

    # rhui-manager repo add_by_file --file /root/example.yaml --sync_now
    The name of the repos being added: Example_YAML_File
    Loading latest entitled products from Red Hat...
    ... listings loaded
    Successfully added Red Hat Enterprise Linux 8 for x86_64 - BaseOS - Extended Update Support from RHUI (RPMs) (8.1) (Yum)
    Successfully added Red Hat Enterprise Linux 8 for x86_64 - BaseOS - Extended Update Support from RHUI (RPMs) (8.2) (Yum)
    Successfully added Red Hat Enterprise Linux 8 for x86_64 - BaseOS - Extended Update Support from RHUI (RPMs) (8.4) (Yum)
    Successfully added Red Hat Enterprise Linux 8 for x86_64 - BaseOS - Extended Update Support from RHUI (RPMs) (8.6) (Yum)
    ... successfully scheduled for the next available timeslot.
    ... successfully scheduled for the next available timeslot.
    ... successfully scheduled for the next available timeslot.
    ... successfully scheduled for the next available timeslot.

検証

  • CLI で、以下のコマンドを使用してインストールされたリポジトリーの一覧を表示し、正しいリポジトリーがインストールされているかどうかを確認します。

    # rhui-manager repo list
  • RHUI 管理ツールのリポジトリー管理画面で、l を押して、インストールされているすべてのリポジトリーを一覧表示し、正しいリポジトリーがインストールされているかどうかを確認します。
Red Hat logoGithubredditYoutubeTwitter

詳細情報

試用、購入および販売

コミュニティー

会社概要

Red Hat は、企業がコアとなるデータセンターからネットワークエッジに至るまで、各種プラットフォームや環境全体で作業を簡素化できるように、強化されたソリューションを提供しています。

多様性を受け入れるオープンソースの強化

Red Hat では、コード、ドキュメント、Web プロパティーにおける配慮に欠ける用語の置き換えに取り組んでいます。このような変更は、段階的に実施される予定です。詳細情報: Red Hat ブログ.

Red Hat ドキュメントについて

Legal Notice

Theme

© 2026 Red Hat
トップに戻る