From ee817c994a2fe60b8e944a4e3533963409541088 Mon Sep 17 00:00:00 2001 From: nain <126972030+nain-F49FF806@users.noreply.github.com> Date: Wed, 21 Feb 2024 19:18:10 +0100 Subject: [PATCH] fix: again, docker copy is weird It tries to resolve symlinks and copy target file. If it's a dangling symlink, no cigar, docker kaputs. So solution (workaround?), copy the parent directory. Apparently then, the symlinks are copied as is. https://github.com/GoogleContainerTools/kaniko/issues/1111#issuecomment-596015015 https://github.com/moby/moby/issues/40449#issuecomment-1545819389 --- Containerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Containerfile b/Containerfile index 2114118..7affe30 100644 --- a/Containerfile +++ b/Containerfile @@ -31,8 +31,8 @@ COPY --from=builder /usr/local/cargo/bin/ /opt/cargo/bin/ COPY --from=builder /usr/local/cargo/.crates.toml /usr/local/cargo/.crates2.json /opt/cargo/ ENV PATH=/opt/cargo/bin:$PATH -COPY customization/rusty-fedora/opt/cargo/bin/* /opt/cargo/bin/ -COPY customization/rusty-fedora/etc/profile.d/* /etc/profile.d/ +COPY customization/rusty-fedora/opt/cargo/bin/ /opt/cargo/bin/ +COPY customization/rusty-fedora/etc/profile.d/ /etc/profile.d/ # --- Ubuntu ---