Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-38862

Failure to Provision HCP Cluster with ACM 2.11 on EC2 Due to Missing AWS_REGION Environment Variable in Hypershift Operator

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not a Bug
    • Icon: Major Major
    • None
    • 4.15, 4.16
    • HyperShift
    • None
    • Hypershift Sprint 259
    • 1
    • False
    • Hide

      None

      Show
      None

      Description of problem:

      Attempting to provision an HCP cluster with ACM 2.11 on EC2 results in a failure with the error: 

      "SupportedHostedCluster condition is false: AWS_REGION environment variable is not set for the operator." 

      The issue appears to stem from the AWS_REGION environment variable not being set in the Hypershift Operator (HO) deployment, which prevents the creation of clusters with

      --endpoint-access=PublicAndPrivate

       

       

      Version-Release number of selected component (if applicable):

      ACM 2.11

      How reproducible:

      This issue is reproducible under the following conditions:

       

      • Deploying an HCP cluster on EC2 using ACM 2.11 with the `--endpoint-access=PublicAndPrivate` option.

       

      Steps to Reproduce:

      1. Attempt to create an HCP cluster using ACM 2.11 on EC2 with the following command:

       

       

      hcp create cluster aws \
          --role-arn arn:aws:iam::<account-id>:role/hcp-cli-role \
          --instance-type m5.large \
          --region us-east-2 \
          --auto-repair \
          --generate-ssh \
          --name <cluster-name> \
          --namespace clusters \
          --base-domain <domain> \
          --node-pool-replicas 1 \
          --pull-secret <path-to-pull-secret> \
          --release-image quay.io/openshift-release-dev/ocp-release:4.15.0-x86_64 \
          --endpoint-access=PublicAndPrivate \
          --sts-creds <path-to-sts-creds.json>
      

       

       

      1. Monitor the ACM console for errors during the cluster provisioning process.
      2. Review the HO deployment configuration for the presence of the AWS_REGION environment variable.

       

      Actual results:

       

      Cluster provisioning fails with the error:

       

      "SupportedHostedCluster condition is false: AWS_REGION environment variable is not set for the operator."

       

       

      Expected results:

      The AWS_REGION environment variable should be automatically set in the HO deployment, allowing successful provisioning of the HCP cluster with `-endpoint-access=PublicAndPrivate.`

       

      Additional info:

      Likely MCE needs to set the right parameters on the hcp cli when creating AWS clusers.

       

      A manual (non-optimal) workaround involves setting the AWS_REGION environment variable in the HO deployment or changing the `--endpoint-access` option to `Public` manually.

              pstefans@redhat.com Patryk Stefanski
              azaalouk Adel Zaalouk
              Liangquan Li Liangquan Li
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: