You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 18, 2025. It is now read-only.
Initial work from @ijc brought a containerized vendoring which was great
but had a few issues:
- did not work on Windows: dependencies containing symlinks could not be
written by golang/dep on a cifs-mounted volume (wich is the case when
mounting a windows dir in Docker Desktop)
- slow: 2 reasons for that: doing the vendoring accross a cifs or osxfs
bind mount was far from ideal due to FS latency and caching issues.
There was no cache preservation between 2 calls.
This fix all those issues by:
- Not using bind mounts: we resolve the vendoring directly in the
container RootFS, then copy back the vendor dir and the Gopkg.lock file
(which might have been updated) to the host
- Mounting a volume in which golang/dep will keep repo info and git
clones in cache
Note that the dep-cache mount point and DEPCACHEDIR env var are
//dep-cache and not /dep-cache. From a Unix FS point of view both paths
are equivalent. But some windows shells (like the bash version shipped
with Git on Windows) tries to do clever conversions to win32 paths when detecting unix-style
paths in command line arguments, which makes docker trying to mount the
volume in "c:\Program Files\Git\bin\..." which makes no sense in a Linux
container. Doubling the initial "/" disable this behavior.
Signed-off-by: Simon Ferquel <[email protected]>
0 commit comments