インストール


builds for Red Hat OpenShift 1.1

Builds のインストール

Red Hat OpenShift Documentation Team

概要

このドキュメントでは、Builds のインストールに関する情報を提供します。

第1章 Builds のインストール

クラスター管理者は、OpenShift Container Platform クラスターに Builds をインストールできます。

1.1. 前提条件

  • OpenShift Container Platform Web コンソールにアクセスできる。
  • oc CLI がインストールされている。
  • 管理者として OpenShift Container Platform クラスターにログインしている。
  • クラスターで Marketplace 機能 が有効になっているか、Red Hat Operator カタログソースが手動で設定されている。
注記

Red Hat OpenShift Pipelines Operator は、依存関係コンポーネントとして、インストール時に Builds for Red Hat OpenShift と合わせて、自動的にインストールされます。Red Hat OpenShift Pipelines Operator がすでにインストールされている場合、Builds はその Operator を使用して機能させます。

1.2. Web コンソールを使用した Builds のインストール

Red Hat OpenShift Web コンソールのビルドを使用して、OperatorHub から Builds for Red Hat OpenShift Operator をインストールできます。この Operator をインストールすると、Build コンポーネントのインストールおよび使用が可能になります。

手順

  1. Web コンソールの Administrator パースペクティブで、OperatorsOperatorHub ページに移動します。
  2. Filter by keyword ボックスを使用して、Builds for Red Hat OpenShift Operator を検索します。
  3. Builds for Red Hat OpenShift Operator タイルをクリックします。
  4. Operator 関する簡単な説明を確認して、Install をクリックします。
  5. Install Operator ページで以下を行います。

    1. Installation ModeAll namespaces on the cluster (default) に設定されていることを確認します。このモードでは、Operator がデフォルトの openshift-builds namespace にインストールされ、クラスター内のすべての namespace で監視および利用できるようになります。
    2. インストールされた namespace がデフォルトで openshift-builds に設定されていることを確認します。
    3. Approval StrategyAutomatic を選択します。これにより、Operator への今後のアップグレードは Operator Lifecycle Manager (OLM) によって自動的に処理されます。Manual 承認ストラテジーを選択すると、OLM は更新要求を作成します。クラスター管理者は、Operator を新規バージョンに更新できるように OLM 更新要求を手動で承認する必要があります。
    4. Update Channel を選択します。

      • Update Channel はデフォルトで latest に設定されます。latest チャネルを使用すると、Builds for Red Hat OpenShift Operator の最新の安定バージョンをインストールできます。
      • Builds for Red Hat OpenShift Operator の特定のバージョンをインストールするには、クラスター管理者は対応する builds-<version> チャネルを使用できます。たとえば、Red Hat OpenShift Operator バージョン 1.1 の Builds をインストールするには、builds- 1.1 チャネルを使用できます。
  6. Install をクリックします。

検証

Builds for Red Hat OpenShift Operator をインストールした後、コントローラーが適切に機能するために必要なリソースが作成されていることを確認する必要があります。

手順

  1. Web コンソールの Administrator パースペクティブで、openshift-builds としてプロジェクトを選択します。
  2. OperatorsInstalled Operators ページに移動します。
  3. All instances タブをクリックします。
  4. All instances タブで、OpenShiftBuild インスタンスおよび ShipwrightBuild インスタンスがリストされていることを確認します。または、OpenShift Build タブと Shipwright Build タブをクリックすることもできます。
  5. 次に、WorkloadsPods ページに移動します。
  6. Pods ページで、次の Pod がリストされていることを確認します。

    • openshift-builds Operator Pod
    • コントローラーを構築し、Webhook Pod を構築する
    • SharedResource デーモンセットと SharedResource Webhook Pod

1.3. CLI を使用した Builds のインストール

コマンドラインインターフェイス (CLI) を使用してビルドをインストールすることもできます。

手順

  1. 以下の例のように、sub.yaml サブスクリプションオブジェクトファイルを作成し、namespace を Red Hat OpenShift Operator の Builds にサブスクライブします。

    apiVersion: operators.coreos.com/v1alpha1
    kind: Subscription
    metadata:
      name: openshift-builds-operator
      namespace: openshift-builds
    spec:
      channel: <channel-name> 1
      name: openshift-builds-operator 2
      source: redhat-operators 3
      sourceNamespace: openshift-marketplace 4
    1
    Operator のサブスクライブ元のチャネル名。
    2
    サブスクライブする Operator の名前。
    3
    Operator を提供する CatalogSource の名前。
    4
    CatalogSource の namespace。デフォルトの OperatorHub CatalogSource には openshift-marketplace を使用します。
  2. 以下のコマンドを実行して subscription オブジェクトを適用します。

    $ oc apply -f sub.yml

    Builds for Red Hat OpenShift Operator が、デフォルトのターゲット namespace openshift-builds にインストールされました。

検証

Builds for Red Hat OpenShift Operator をインストールした後、Operator が適切に機能することを確認するために、次のリソースが作成されていることを確認する必要があります。

  1. 次のコマンドを実行して、OpenshiftBuild リソースが作成されていることを確認します。

    $ oc get openshiftbuilds
  2. 次のコマンドを実行して、ShipwrightBuilds リソースが作成されていることを確認します。

    $ oc get shipwrightbuilds
  3. 次のコマンドを実行して、openshift-builds namespace に次の Pod が作成されていることを確認します。

    • openshift-builds Operator Pod
    • コントローラーを構築し、Webhook Pod を構築する
    • SharedResource デーモンセットと SharedResource Webhook Pod

      $ oc get pods -n openshift-builds

      Pod のリストは次の例のように表示されます。

      $ oc get pods -n openshift-builds
      NAME                                                 READY   STATUS    RESTARTS   AGE
      openshift-builds-operator-6f5c48c6b5-cvp2w           2/2     Running   0          13d
      openshift-pipelines-operator-64d8c4969c-952cc        2/2     Running   0          3d13h
      shared-resource-csi-driver-node-gbkqs                2/2     Running   0          13d
      shared-resource-csi-driver-node-kcqxc                2/2     Running   0          13d
      shared-resource-csi-driver-node-sbsvg                2/2     Running   0          13d
      shared-resource-csi-driver-webhook-9d9bd48f4-d5ln6   1/1     Running   0          13d
      shipwright-build-controller-5454475b85-mmm6w         1/1     Running   0          13d
      shipwright-build-webhook-7fbd49c6bb-2n77s            1/1     Running   0          13d
      tekton-operator-webhook-756f5dfdc7-c99mc             1/1     Running   0          3d13h

1.4. ShipwrightBuilds ビルドコントローラーと Webhook Pod の無効化

共有リソースの Container Storage Interface (CSI) ドライバーコンポーネントと ShipwrightBuilds カスタムリソース定義 (CRD) を無効にせずに、ShipwrightBuilds カスタムリソース (CR) を無効にできます。ShipwrightBuilds CR を無効にすると、ShipwrightBuilds ビルドコントローラーと ShipwrightBuilds ビルド Webhook Pod が openshift-builds namespace から削除されます。

手順

  • 次のコマンドを実行して、ShipwrightBuilds コントローラーと Webhook を無効にします。

    $ oc patch openshiftbuild cluster --type=merge -p '{"spec":{"shipwright":{"build":{"state":"Disabled"}}}}'

    このコマンドはビルドコントローラーと Webhook を無効にしますが、ShipwrightBuilds CRD には影響しません。

1.5. 関連情報

Legal Notice

Copyright © 2024 Red Hat, Inc.

OpenShift documentation is licensed under the Apache License 2.0 (https://www.apache.org/licenses/LICENSE-2.0).

Modified versions must remove all Red Hat trademarks.

Portions adapted from https://github.com/kubernetes-incubator/service-catalog/ with modifications by Red Hat.

Red Hat, Red Hat Enterprise Linux, the Red Hat logo, the Shadowman logo, JBoss, OpenShift, Fedora, the Infinity logo, and RHCE are trademarks of Red Hat, Inc., registered in the United States and other countries.

Linux® is the registered trademark of Linus Torvalds in the United States and other countries.

Java® is a registered trademark of Oracle and/or its affiliates.

XFS® is a trademark of Silicon Graphics International Corp. or its subsidiaries in the United States and/or other countries.

MySQL® is a registered trademark of MySQL AB in the United States, the European Union and other countries.

Node.js® is an official trademark of Joyent. Red Hat Software Collections is not formally related to or endorsed by the official Joyent Node.js open source or commercial project.

The OpenStack® Word Mark and OpenStack logo are either registered trademarks/service marks or trademarks/service marks of the OpenStack Foundation, in the United States and other countries and are used with the OpenStack Foundation’s permission. We are not affiliated with, endorsed or sponsored by the OpenStack Foundation, or the OpenStack community.

All other trademarks are the property of their respective owners.

Red Hat logoGithubRedditYoutubeTwitter

詳細情報

試用、購入および販売

コミュニティー

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

Red Hat をお使いのお客様が、信頼できるコンテンツが含まれている製品やサービスを活用することで、イノベーションを行い、目標を達成できるようにします。

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

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

会社概要

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

© 2024 Red Hat, Inc.