Skip to content
This repository was archived by the owner on Jun 3, 2025. It is now read-only.

Add more tests for Copy and some fixes.#1114

Merged
tejal29 merged 6 commits intoGoogleContainerTools:masterfrom
tejal29:fix_copy
Mar 10, 2020
Merged

Add more tests for Copy and some fixes.#1114
tejal29 merged 6 commits intoGoogleContainerTools:masterfrom
tejal29:fix_copy

Conversation

@tejal29
Copy link
Copy Markdown
Contributor

@tejal29 tejal29 commented Mar 7, 2020

Fixes to #1111 , #1110
In #1111, @gilbsgilbs metioned, copy symlink files should not be evaluated.

I started testing what docker build does and found

  1. docker build creates symlinks when copying a single file which is a symlink
    see Dockerfile COPY from image resolves symbolic links moby/moby#40449
  2. docker build preserves the symlink when copying a dir.

Kaniko, copy command was always creating a regular file.

While adding tests for copyCommand i found few issues.

  1. If dest was a directory in the context workspace, it wasn't identified as dir.
  2. Missed errors.Wrap that i found while debuging issues.

Please see all the scenarios tested with docker build here #1111 (comment)

@googlebot googlebot added the cla: yes CLA signed by all commit authors label Mar 7, 2020
@tejal29 tejal29 changed the title Add more tests for Copy and some minor fixes. Add more tests for Copy and some fixes. Mar 10, 2020
@tejal29 tejal29 merged commit c718dc6 into GoogleContainerTools:master Mar 10, 2020
@tejal29 tejal29 deleted the fix_copy branch April 26, 2021 16:43
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

cla: yes CLA signed by all commit authors kokoro:run

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants