Uploaded image for project: 'Red Hat Developer Hub Bugs'
  1. Red Hat Developer Hub Bugs
  2. RHDHBUGS-2752

--extra-images of prepare-restricted-environment.sh has yaml formatting error

XMLWordPrintable

    • 1
    • False
    • Hide

      None

      Show
      None
    • False
    • Hide
      == Fixed incorrect indentation of `additionalImages` in ImageSetConfiguration file generated by the prepare-restricted-environment.sh when called with `--use-oc-mirror`

      Before this update, incorrect indentation of the `additionalImages` field in the `ImageSetConfiguration` manifest generated by the `prepare-restricted-environment.sh` script caused a conversion error when trying to mirror images using `oc-mirror`.
      With this release, the indentation of `additionalImages` in the ImageSetConfiguration object has been fixed and calls to `oc-mirror` now work correctly.
      Show
      == Fixed incorrect indentation of `additionalImages` in ImageSetConfiguration file generated by the prepare-restricted-environment.sh when called with `--use-oc-mirror` Before this update, incorrect indentation of the `additionalImages` field in the `ImageSetConfiguration` manifest generated by the `prepare-restricted-environment.sh` script caused a conversion error when trying to mirror images using `oc-mirror`. With this release, the indentation of `additionalImages` in the ImageSetConfiguration object has been fixed and calls to `oc-mirror` now work correctly.
    • Bug Fix
    • RHDH Install 3288

      Description of problem:

       

      Incorrect indentation for the additionalImages stanza in the ImageSetConfiguration object leads to an error from oc-mirror

      additionalImages needs to be at the same column as operators per the examples in the OCP docs like the ImageSetConfiguration example at https://docs.redhat.com/en/documentation/openshift_container_platform/4.21/html/disconnected_environments/about-installing-oc-mirror-v2#oc-mirror-building-image-set-config-v2_about-installing-oc-mirror-v2 

      Prerequisites (if any, like setup, operators/versions):

      Steps to Reproduce

       An invocation like 

      ```

      gmontero ~/go/src/github.com/redhat-developer/rhdh-operator  (air-gap-lt-spd)$ bash .rhdh/scripts/prepare-restricted-environment.sh -install-operator false  -use-oc-mirror true   --to-registry quay.io/gabemontero/rhdh   --filter-versions "1.8" --extra-images quay.io/lightspeed-core/lightspeed-stack:0.4.0,quay.io/redhat-ai-dev/llama-stack:0.1.4,quay.io/redhat-ai-dev/rag-content:release-1.9-lcs

      ```

      Actual results:

      GGM start oc-mirror in to registry path with registry url quay.io/gabemontero/rhdh and flags
      GGM start cat imageset-config.yaml
      apiVersion: mirror.openshift.io/v2alpha1
      kind: ImageSetConfiguration
      mirror:
        operators:
        - catalog: registry.redhat.io/redhat/redhat-operator-index:v4.18
          full: false
          targetCatalog: rhdh-catalog
          packages:
            - name: rhdh
              channels:
                - name: fast
                - name: fast-1.8
            additionalImages:
            - name: "quay.io/lightspeed-core/lightspeed-stack:0.4.0"
            - name: "quay.io/redhat-ai-dev/llama-stack:0.1.4"
            - name: "quay.io/redhat-ai-dev/rag-content:release-1.9-lcs"
      GGM end cat imageset-config.yaml
      2026/03/02 15:40:58  [INFO]   : 👋 Hello, welcome to oc-mirror
      2026/03/02 15:40:58  [INFO]   : ⚙️  setting up the environment for you...
      2026/03/02 15:40:58  [ERROR]  : [Executor] failed to unmarshal config: error converting YAML to JSON: yaml: line 12: did not find expected '-' indicator

      Expected results:

      Reproducibility (Always/Intermittent/Only Once):

      Build Details:

      I ran this with commit level a5b22571b0564d10317f4b9330ce6c3785c448e2 from the rhdh-operator repo (March 2)

      Additional info (Such as Logs, Screenshots, etc):

      I have a fix in hand

              gmontero@redhat.com Gabe Montero
              gmontero@redhat.com Gabe Montero
              RHDH Install
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: