Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dockerclient COPY --from: go back and copy skipped hard link targets #203

Merged

Conversation

nalind
Copy link
Member

@nalind nalind commented Oct 13, 2021

If we're copying from another stage or from an archive, and we encounter an entry that we need to copy that should be hard linked to an entry that we would have skipped, run through another copy of the archive, convert the hard link entry we're processing into a regular file entry, and use the contents of the skipped item as the contents for the regular file entry. Rewrite any subsequent links to the skipped entry into links to the first link, which we converted into the regular file.

Fixes #202.

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 13, 2021
@nalind nalind force-pushed the copy-omitted-hard-links branch 2 times, most recently from 2a3d4ca to 73e7f81 Compare October 13, 2021 20:23
If we're copying from another stage or from an archive, and we encounter
an entry that we need to copy that should be hard linked to an entry
that we would have skipped, run through another copy of the archive,
convert the hard link entry we're processing into a regular file entry,
and use the contents of the skipped item as the contents for the regular
file entry.  Rewrite any subsequent links to the skipped entry into
links to the first link, which we converted into the regular file.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
@TomSweeneyRedHat
Copy link
Contributor

This one is stretching my brain cells, but LGTM. Definitely want a head nod from a couple of other folks. @rhatdan @mrunalp?

@rhatdan
Copy link
Contributor

rhatdan commented Oct 18, 2021

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Oct 18, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 18, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: nalind, rhatdan

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-robot openshift-merge-robot merged commit 06a1ba4 into openshift:master Oct 18, 2021
@nalind nalind deleted the copy-omitted-hard-links branch October 18, 2021 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

issue in COPY from one stage to next
4 participants