Amazon Elastic Kubernetes Service への Red Hat Developer Hub のインストール


Red Hat Developer Hub 1.2

Red Hat Customer Content Services

概要

Red Hat Developer Hub は、開発者ポータルを構築するためのエンタープライズグレードのプラットフォームです。管理ユーザーは、ロール、権限、その他の設定を設定することで、Operator または Helm チャートを使用して Amazon Elastic Kubernetes Service (EKS) に Developer Hub のインスタンスをデプロイすることを、他のユーザーに許可できます。

第1章 Elastic Kubernetes Service (EKS) への Red Hat Developer Hub のインストール

次のいずれかの方法を使用して、Amazon Elastic Kubernetes Service (EKS) に Red Hat Developer Hub をインストールできます。

  • Red Hat Developer Hub Operator
  • Red Hat Developer Hub Helm チャート

1.1. Operator を使用した EKS への Developer Hub のインストール

Red Hat Developer Hub Operator のインストールには、Operator Lifecycle Manager (OLM) フレームワークが必要です。

関連情報

1.1.1. OLM フレームワークを使用した Developer Hub Operator のインストール

Operator Lifecycle Manager (OLM) フレームワーク を使用して、EKS に Developer Hub Operator をインストールできます。その後、EKS に Developer Hub インスタンスをデプロイできます。

前提条件

手順

  1. ターミナルで次のコマンドを実行して、Operator がインストールされている rhdh-operator namespace を作成します。

    kubectl create namespace rhdh-operator
  2. 次のコマンドを使用してプルシークレットを作成します。

    kubectl -n rhdh-operator create secret docker-registry rhdh-pull-secret \
        --docker-server=registry.redhat.io \
        --docker-username=<user_name> \ 
    1
    
        --docker-password=<password> \ 
    2
    
        --docker-email=<email> 
    3
    1
    コマンドにユーザー名を入力します。
    2
    コマンドにパスワードを入力します。
    3
    コマンドにメールアドレスを入力します。

    作成されたプルシークレットは、Red Hat Ecosystem から Developer Hub イメージをプルするために使用されます。

  3. Red Hat Ecosystem からの Operator を含む CatalogSource リソースを作成します。

    cat <<EOF | kubectl -n rhdh-operator apply -f -
    apiVersion: operators.coreos.com/v1alpha1
    kind: CatalogSource
    metadata:
      name: redhat-catalog
    spec:
      sourceType: grpc
      image: registry.redhat.io/redhat/redhat-operator-index:v4.15
      secrets:
      - "rhdh-pull-secret"
      displayName: Red Hat Operators
    EOF
  4. 次のように OperatorGroup リソースを作成します。

    cat <<EOF | kubectl apply -n rhdh-operator -f -
    apiVersion: operators.coreos.com/v1
    kind: OperatorGroup
    metadata:
      name: rhdh-operator-group
    EOF
  5. 次のコードを使用して Subscription リソースを作成します。

    cat <<EOF | kubectl apply -n rhdh-operator -f -
    apiVersion: operators.coreos.com/v1alpha1
    kind: Subscription
    metadata:
      name: rhdh
      namespace: rhdh-operator
    spec:
      channel: fast
      installPlanApproval: Automatic
      name: rhdh
      source: redhat-catalog
      sourceNamespace: rhdh-operator
      startingCSV: rhdh-operator.v1.2.6
    EOF
  6. 次のコマンドを実行して、作成した Operator が実行されていることを確認します。

    kubectl -n rhdh-operator get pods -w

    Operator Pod に ImagePullBackOff ステータスが表示される場合は、Operator デプロイメントのマニフェスト内でイメージを直接プルする権限が必要な場合があります。

    ヒント

    必要なシークレット名を deployment.spec.template.spec.imagePullSecrets リストに含め、kubectl get deployment -n rhdh-operator コマンドを使用してデプロイメント名を確認できます。

    kubectl -n rhdh-operator patch deployment \
        rhdh.fast --patch '{"spec":{"template":{"spec":{"imagePullSecrets":[{"name":"rhdh-pull-secret"}]}}}}' \
        --type=merge
  7. 次の手順を使用して Operator のデフォルト設定を更新して、Developer Hub リソースが EKS で正常に起動できるようにします。

    1. 次のコマンドを使用して、rhdh-operator namespace の backstage-default-config ConfigMap を編集します。

      kubectl -n rhdh-operator edit configmap backstage-default-config
    2. 次の例に示すように、db-statefulset.yaml 文字列を見つけて、その spec.template.spec.securityContextfsGroup を追加します。

        db-statefulset.yaml: |
          apiVersion: apps/v1
          kind: StatefulSet
      --- TRUNCATED ---
          spec:
          --- TRUNCATED ---
            restartPolicy: Always
            securityContext:
            # You can assign any random value as fsGroup
              fsGroup: 2000
            serviceAccount: default
            serviceAccountName: default
      --- TRUNCATED ---
    3. 次の例に示すように、deployment.yaml 文字列を見つけて、その仕様に fsGroup を追加します。

        deployment.yaml: |
          apiVersion: apps/v1
          kind: Deployment
      --- TRUNCATED ---
          spec:
            securityContext:
              # You can assign any random value as fsGroup
              fsGroup: 3000
            automountServiceAccountToken: false
      --- TRUNCATED ---
    4. 次のように、service.yaml 文字列を見つけて、typeNodePort に変更します。

        service.yaml: |
          apiVersion: v1
          kind: Service
          spec:
           # NodePort is required for the ALB to route to the Service
            type: NodePort
      --- TRUNCATED ---
    5. 保存して終了します。

      変更が Operator Pod に自動的に適用されるまで、数分間待ちます。

1.1.2. Operator を使用した EKS への Developer Hub インスタンスのデプロイ

前提条件

手順

  1. 次のテンプレートを使用して、Developer Hub 設定を含む app-config-rhdh という名前の ConfigMap を作成します。

    apiVersion: v1
    kind: ConfigMap
    metadata:
      name: app-config-rhdh
    data:
      "app-config-rhdh.yaml": |
        app:
          title: Red Hat Developer Hub
          baseUrl: https://<rhdh_dns_name>
        backend:
          auth:
            keys:
              - secret: "${BACKEND_SECRET}"
          baseUrl: https://<rhdh_dns_name>
          cors:
            origin: https://<rhdh_dns_name>
  2. secrets-rhdh という名前の Secret を作成し、値として Base64-encoded 文字列を持つ BACKEND_SECRET という名前のキーを追加します。

    apiVersion: v1
    kind: Secret
    metadata:
      name: secrets-rhdh
    stringData:
      # TODO: See https://backstage.io/docs/auth/service-to-service-auth/#setup
      BACKEND_SECRET: "xxx"
    重要

    各 Developer Hub インスタンスには、必ず一意の値の BACKEND_SECRET を使用してください。

    次のコマンドを使用してキーを生成できます。

    node-p'require("crypto").randomBytes(24).toString("base64")'
  3. Red Hat エコシステムカタログから PostgreSQL イメージをプルできるようにするには、Developer Hub インスタンスがデプロイされている namespace 内のデフォルトのサービスアカウントにイメージプルシークレットを追加します。

    kubectl patch serviceaccount default \
        -p '{"imagePullSecrets": [{"name": "rhdh-pull-secret"}]}' \
        -n <your_namespace>
  4. 次のテンプレートを使用してカスタムリソースファイルを作成します。

    apiVersion: rhdh.redhat.com/v1alpha1
    kind: Backstage
    metadata:
     # TODO: this the name of your Developer Hub instance
      name: my-rhdh
    spec:
      application:
        imagePullSecrets:
        - "rhdh-pull-secret"
        route:
          enabled: false
        appConfig:
          configMaps:
            - name: "app-config-rhdh"
        extraEnvs:
          secrets:
            - name: "secrets-rhdh"
  5. 次のテンプレートを使用して Ingress リソースを作成し、必要に応じて名前をカスタマイズします。

    apiVersion: networking.k8s.io/v1
    kind: Ingress
    metadata:
      # TODO: this the name of your Developer Hub Ingress
      name: my-rhdh
      annotations:
        alb.ingress.kubernetes.io/scheme: internet-facing
    
        alb.ingress.kubernetes.io/target-type: ip
    
        # TODO: Using an ALB HTTPS Listener requires a certificate for your own domain. Fill in the ARN of your certificate, e.g.:
        alb.ingress.kubernetes.io/certificate-arn: arn:aws:acm:us-xxx:xxxx:certificate/xxxxxx
    
         alb.ingress.kubernetes.io/listen-ports: '[{"HTTP": 80}, {"HTTPS":443}]'
    
        alb.ingress.kubernetes.io/ssl-redirect: '443'
    
        # TODO: Set your application domain name.
        external-dns.alpha.kubernetes.io/hostname: <rhdh_dns_name>
    
    spec:
      ingressClassName: alb
      rules:
        # TODO: Set your application domain name.
        - host: <rhdh_dns_name>
          http:
            paths:
            - path: /
              pathType: Prefix
              backend:
                service:
                  # TODO: my-rhdh is the name of your Backstage Custom Resource.
                  # Adjust if you changed it!
                  name: backstage-my-rhdh
                  port:
                    name: http-backend

    前のテンプレートで、`<rhdh_dns_name>` を Developer Hub ドメイン名に置き換え、alb.ingress.kubernetes.io/certificate-arn の値を証明書 ARN で更新します。

検証

DNS 名が応答し、Developer Hub インスタンスが使用できる状態になったことを示すまで待ちます。

1.2. Helm チャートを使用した EKS への Developer Hub のインストール

Elastic Kubernetes Service (EKS) に Developer Hub Helm チャートをインストールすると、Developer Hub インスタンスのデプロイがオーケストレーションされます。これにより、AWS エコシステム内で堅牢な開発者プラットフォームが実現します。

前提条件

手順

  1. ターミナルに移動し、次のコマンドを実行して、Developer Hub チャートを含む Helm チャートリポジトリーを、ローカルの Helm レジストリーに追加します。

    helm repo add openshift-helm-charts https://charts.openshift.io/
  2. 次のコマンドを使用してプルシークレットを作成します。

    kubectl create secret docker-registry rhdh-pull-secret \
        --docker-server=registry.redhat.io \
        --docker-username=<user_name> \ 
    1
    
        --docker-password=<password> \ 
    2
    
        --docker-email=<email> 
    3
    1
    コマンドにユーザー名を入力します。
    2
    コマンドにパスワードを入力します。
    3
    コマンドにメールアドレスを入力します。

    作成されたプルシークレットは、Red Hat Ecosystem から Developer Hub イメージをプルするために使用されます。

  3. 次のテンプレートを使用して、values.yaml という名前のファイルを作成します。

    global:
      # TODO: Set your application domain name.
      host: <your Developer Hub domain name>
    
    
    route:
      enabled: false
    
    
    upstream:
      service:
        # NodePort is required for the ALB to route to the Service
        type: NodePort
    
    
      ingress:
        enabled: true
        annotations:
          kubernetes.io/ingress.class: alb
    
    
          alb.ingress.kubernetes.io/scheme: internet-facing
    
    
          # TODO: Using an ALB HTTPS Listener requires a certificate for your own domain. Fill in the ARN of your certificate, e.g.:
          alb.ingress.kubernetes.io/certificate-arn: arn:aws:acm:xxx:xxxx:certificate/xxxxxx
    
    
          alb.ingress.kubernetes.io/listen-ports: '[{"HTTP": 80}, {"HTTPS":443}]'
    
    
          alb.ingress.kubernetes.io/ssl-redirect: '443'
    
    
          # TODO: Set your application domain name.
          external-dns.alpha.kubernetes.io/hostname: <your rhdh domain name>
    
    
      backstage:
        image:
          pullSecrets:
          - rhdh-pull-secret
        podSecurityContext:
          # you can assign any random value as fsGroup
          fsGroup: 2000
      postgresql:
        image:
          pullSecrets:
          - rhdh-pull-secret
        primary:
          podSecurityContext:
            enabled: true
            # you can assign any random value as fsGroup
            fsGroup: 3000
      volumePermissions:
        enabled: true
  4. ターミナルで次のコマンドを実行し、最新バージョンの Helm Chart と前の手順で作成した value.yaml ファイルを使用して Developer Hub をデプロイします。

    helm install rhdh \
      openshift-helm-charts/redhat-developer-hub \
      [--version 1.2.6] \
      --values /path/to/values.yaml
注記

最新のチャートバージョンは、https://github.com/openshift-helm-charts/charts/tree/main/charts/redhat/redhat/redhat-developer-hub を参照してください。

検証

DNS 名が応答し、Developer Hub インスタンスが使用できる状態になったことを示すまで待ちます。

法律上の通知

Copyright © 2025 Red Hat, Inc.
The text of and illustrations in this document are licensed by Red Hat under a Creative Commons Attribution–Share Alike 3.0 Unported license ("CC-BY-SA"). An explanation of CC-BY-SA is available at http://creativecommons.org/licenses/by-sa/3.0/. In accordance with CC-BY-SA, if you distribute this document or an adaptation of it, you must provide the URL for the original version.
Red Hat, as the licensor of this document, waives the right to enforce, and agrees not to assert, Section 4d of CC-BY-SA to the fullest extent permitted by applicable law.
Red Hat, Red Hat Enterprise Linux, the Shadowman logo, the Red Hat 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 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 は、企業がコアとなるデータセンターからネットワークエッジに至るまで、各種プラットフォームや環境全体で作業を簡素化できるように、強化されたソリューションを提供しています。

Theme

© 2026 Red Hat
トップに戻る