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

virtual hosted-style doesn't work since 4.14

XMLWordPrintable

    • Low
    • Yes
    • False
    • Hide

      None

      Show
      None
    • Hide
      * Previously, when the `virtualHostedStyle` parameter was set to `regionEndpoint` in the Image Registry Operator configuration, the image registry ignored the virtual hosted style configuration. With this release, the issue is resolved so that a new upstream distribution configuration, force path style, is used instead of the downstream only version, virtual hosted style. (link:https://issues.redhat.com/browse/OCPBUGS-234166[*OCPBUGS-34166*])
      Show
      * Previously, when the `virtualHostedStyle` parameter was set to `regionEndpoint` in the Image Registry Operator configuration, the image registry ignored the virtual hosted style configuration. With this release, the issue is resolved so that a new upstream distribution configuration, force path style, is used instead of the downstream only version, virtual hosted style. (link: https://issues.redhat.com/browse/OCPBUGS-234166 [* OCPBUGS-34166 *])
    • Bug Fix
    • Done

      This is a clone of issue OCPBUGS-32710. The following is the description of the original issue:

      Description of problem:

          When enabled virtualHostedStyle with regionEndpoint set in config.image/cluster , image registry failed to be running. errors throw:
      
      time="2024-04-22T14:14:31.057192227Z" level=error msg="s3aws: RequestError: send request failed\ncaused by: Get \"https://s3-fips.us-west-1.amazonaws.com/ci-ln-67zbmzk-76ef8-4n6wb-image-registry-us-west-1-xjyfbabyboc?list-type=2&max-keys=1&prefix=\": dial tcp: lookup s3-fips.us-west-1.amazonaws.com on 172.30.0.10:53: no such host" go.version="go1.20.12 X:strictfipsruntime" 

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

          4.14.18

      How reproducible:

          always

      Steps to Reproduce:

          1.
      $ oc get config.imageregistry/cluster -ojsonpath="{.status.storage}"|jq 
      {
        "managementState": "Managed",
        "s3": {
          "bucket": "ci-ln-67zbmzk-76ef8-4n6wb-image-registry-us-west-1-xjyfbabyboc",
          "encrypt": true,
          "region": "us-west-1",
          "regionEndpoint": "https://s3-fips.us-west-1.amazonaws.com",
          "trustedCA": {
            "name": ""
          },
          "virtualHostedStyle": true
        }
      }     
          2. Check registry pod
      $ oc get co image-registry
      NAME             VERSION   AVAILABLE   PROGRESSING   DEGRADED   SINCE   MESSAGE
      image-registry   4.15.5    True        True          True       79m     Degraded: Registry deployment has timed out progressing: ReplicaSet "image-registry-b6c58998d" has timed out progressing
          
          

      Actual results:

      $ oc get pods image-registry-b6c58998d-m8pnb -oyaml| yq '.spec.containers[0].env'
      - name: REGISTRY_STORAGE_S3_REGIONENDPOINT
        value: https://s3-fips.us-west-1.amazonaws.com
      [...]
      - name: REGISTRY_STORAGE_S3_VIRTUALHOSTEDSTYLE
        value: "true"
      [...]
      
      $ oc logs image-registry-b6c58998d-m8pnb
      [...]
      time="2024-04-22T14:14:31.057192227Z" level=error msg="s3aws: RequestError: send request failed\ncaused by: Get \"https://s3-fips.us-west-1.amazonaws.com/ci-ln-67zbmzk-76ef8-4n6wb-image-registry-us-west-1-xjyfbabyboc?list-type=2&max-keys=1&prefix=\": dial tcp: lookup s3-fips.us-west-1.amazonaws.com on 172.30.0.10:53: no such host" go.version="go1.20.12 X:strictfipsruntime"     

      Expected results:

          virtual hosted-style should work

      Additional info:

          

              fmissi Flavian Missi
              openshift-crt-jira-prow OpenShift Prow Bot
              XiuJuan Wang XiuJuan Wang
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: