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

Copying symlink from previous stage fails instead of overwriting #442

Closed
aduong opened this issue Nov 9, 2018 · 0 comments
Closed

Copying symlink from previous stage fails instead of overwriting #442

aduong opened this issue Nov 9, 2018 · 0 comments
Labels
kind/bug Something isn't working

Comments

@aduong
Copy link
Contributor

aduong commented Nov 9, 2018

Actual behavior
COPY --from=0 X Y where X is a symlink from stage 0 and Y is an pre-existing symlink in the current stage fails with "file exists".

Expected behavior
COPY --from=0 X Y where X is a symlink from stage 0 and Y is a pre-existing symlink in the current stage should overwrite Y with X as it would if neither were symlinks.

To Reproduce

docker run --rm -v $PWD:/workspace:ro gcr.io/kaniko-project/executor:v0.6.0 --no-push

with the following Dockerfile:

FROM python:slim

FROM python:slim
COPY --from=0 /usr/local/lib/libpython3.7m.so /usr/local/lib/libpython3.7m.so

Although this is a bit contrived, we had a Dockerfile which was building into /usr/local/lib and then copying that into the final stage which seems like a legitimate use-case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants