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

oc image extract fails on symlink

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not a Bug
    • Icon: Major Major
    • None
    • 4.19, 4.20
    • oc
    • None
    • Quality / Stability / Reliability
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • None
    • None
    • None
    • Proposed
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Description of the problem

      Version-Release number of selected component (if applicable)

      All

      How reproducible

      Use this containerfile

      FROM registry.redhat.io/ubi8/ubi:latest
      RUN dnf -y install network-scripts

      This is how it looks like on disk:

      $ ls -l ./usr/share/man/man8/
      total 12
      lrwxrwxrwx. 1 proguski proguski  52 Aug 10  2022 ifdown.8.gz -> ../../../../../../../../usr/share/man/man8/ifup.8.gz
      -rw-r--r--. 1 proguski proguski 555 Aug 10  2022 ifup.8.gz
      -rw-r--r--. 1 proguski proguski 689 Aug 10  2022 usernetctl.8.gz
      

      Then oc image extract <result> will throw an error:

      Actual results:

      invalid symlink "/work/content/content-amd64/usr/share/man/man8/ifdown.8.gz" -> "../../../../../../../../usr/share/man/man8/ifup.8.gz
      

      Expected results

      Layer gets extracted

      Additional info

      This functionality is being used in the Konflux release pipeline, and images containing this rpm are not able to ship without getting waved.

              aos-workloads-staff Workloads Team Bot Account
              jdelft Joep van Delft
              None
              None
              Ying Zhou Ying Zhou
              None
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: