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

Failed to mirror ocp payload when use digest not the tag

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Critical Critical
    • None
    • 4.18
    • oc-mirror
    • Moderate
    • Yes
    • Proposed
    • False
    • Hide

      None

      Show
      None
    • Hide
      *Cause*: What actions or circumstances cause this bug to present.
      *Consequence*: What happens when the bug presents.
      *Fix*: What was done to fix the bug.
      *Result*: Bug doesn’t present anymore.
      Show
      *Cause*: What actions or circumstances cause this bug to present. *Consequence*: What happens when the bug presents. *Fix*: What was done to fix the bug. *Result*: Bug doesn’t present anymore.
    • Bug Fix
    • In Progress

      Description of problem:

      when mirror ocp payload with digest will failed with error : 
      invalid destination name docker://ci-op-n2k1twzy-c1a88-bastion-mirror-registry-xxxxxxxx-zhouy.apps.yinzhou-1031.qe.devcluster.openshift.com/ci-op-n2k1twzy/release/openshift/release-images:: invalid reference format

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

      ./oc-mirror.rhel8  version 
      WARNING: This version information is deprecated and will be replaced with the output from --short. Use --output=yaml|json to get the full version.
      Client Version: version.Info{Major:"", Minor:"", GitVersion:"4.18.0-202410251041.p0.g95f0611.assembly.stream.el9-95f0611", GitCommit:"95f0611c1dc9584a4a9e857912b9eaa539234bbc", GitTreeState:"clean", BuildDate:"2024-10-25T11:28:19Z", GoVersion:"go1.22.7 (Red Hat 1.22.7-1.module+el8.10.0+22325+dc584f75) X:strictfipsruntime", Compiler:"gc", Platform:"linux/amd64"}

      How reproducible:

           Always
          

      Steps to Reproduce:

      1. imagesetconfig with digest for ocp payload :
      cat config.yaml 
      kind: ImageSetConfiguration
      apiVersion: mirror.openshift.io/v2alpha1
      mirror:
        platform:
          release: registry.ci.openshift.org/ocp/release@sha256:e87cdacdf5c575ff99d4cca7ec38758512a408ac1653fef8dd7b2c4b85e295f4
      
      2. run the mirror2mirror command :
      ./oc-mirror.rhel8.18 -c config.yaml docker://ci-op-n2k1twzy-c1a88-bastion-mirror-registry-xxxxxxxx-zhouy.apps.yinzhou-1031.qe.devcluster.openshift.com/ci-op-n2k1twzy/release --dest-tls-verify=false --v2 --workspace file://out1  --authfile auth.json

       

      Actual results:

      2. hit error :
      
       ✗   188/188 : (2s) registry.ci.openshift.org/ocp/release@sha256:e87cdacdf5c575ff99d4cca7ec38758512a408ac1653fef8dd7b2c4b85e295f4 
      2024/10/31 06:20:03  [INFO]   : 👋 Goodbye, thank you for using oc-mirror
      2024/10/31 06:20:03  [ERROR]  : invalid destination name docker://ci-op-n2k1twzy-c1a88-bastion-mirror-registry-xxxxxxxx-zhouy.apps.yinzhou-1031.qe.devcluster.openshift.com/ci-op-n2k1twzy/release/openshift/release-images:: invalid reference format

      Expected results:

      3. no error

      Additional info:

      compared with 4.17 oc-mirror, no such issue :   ./oc-mirror -c config.yaml docker://ci-op-n2k1twzy-c1a88-bastion-mirror-registry-xxxxxxxx-zhouy.apps.yinzhou-1031.qe.devcluster.openshift.com/ci-op-n2k1twzy/release --dest-tls-verify=false --v2 --workspace file://out1  --authfile auth.json 2024/10/31 06:23:04  [WARN]   : ⚠️  --v2 flag identified, flow redirected to the oc-mirror v2 version. This is Tech Preview, it is still under development and it is not production ready.
      2024/10/31 06:23:04  [INFO]   : 👋 Hello, welcome to oc-mirror
      ...
       ✓   188/188 : (1s) registry.ci.openshift.org/ocp/release@sha256:e87cdacdf5c575ff99d4cca7ec38758512a408ac1653fef8dd7b2c4b85e295f4 
      2024/10/31 06:27:58  [INFO]   : === Results ===
      2024/10/31 06:27:58  [INFO]   : ✅ 188 / 188 release images mirrored successfully
      2024/10/31 06:27:58  [INFO]   : 📄 Generating IDMS file...
      2024/10/31 06:27:58  [INFO]   : out1/working-dir/cluster-resources/idms-oc-mirror.yaml file created
      2024/10/31 06:27:58  [INFO]   : 📄 No images by tag were mirrored. Skipping ITMS generation.
      2024/10/31 06:27:58  [INFO]   : 📄 No catalogs mirrored. Skipping CatalogSource file generation.
      2024/10/31 06:27:58  [INFO]   : mirror time     : 4m54.452548695s
      2024/10/31 06:27:58  [INFO]   : 👋 Goodbye, thank you for using oc-mirror
        

       

            luzuccar@redhat.com Luigi Mario Zuccarelli
            yinzhou@redhat.com ying zhou
            ying zhou ying zhou
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: