-
Notifications
You must be signed in to change notification settings - Fork 44
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
copy: add fast copy path for darwin #66
Conversation
Signed-off-by: Tonis Tiigi <[email protected]>
Should you have an |
It already exists for linux/windows. We don't have any way to test others anyway. |
@@ -52,6 +52,21 @@ func (c *copier) copyFileInfo(fi os.FileInfo, name string) error { | |||
return nil | |||
} | |||
|
|||
func copyFile(source, target string) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you could call this copyFileNaive
in copy.go
and call it as a fallback from darwin.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But this function is not naive in linux. It does copy_file_range on linux.
full diff: tonistiigi/fsutil@3bbb99c...3d2716d - tonistiigi/fsutil#66 copy: add fast copy path for darwin - tonistiigi/fsutil#67 Treat Unix sockets as regular files Signed-off-by: Sebastiaan van Stijn <[email protected]>
full diff: tonistiigi/fsutil@3bbb99c...0f039a0 - tonistiigi/fsutil#66 copy: add fast copy path for darwin - tonistiigi/fsutil#67 Treat Unix sockets as regular files - relates to moby/buildkit#1144 Fix socket handling - tonistiigi/fsutil#68 fix gocrypto commit - tonistiigi/fsutil#69 receive: use filter on receive diff - prevents incremental transfers with userns because the metadata on disk is always different than the one being transferred. Signed-off-by: Sebastiaan van Stijn <[email protected]>
full diff: tonistiigi/fsutil@3bbb99c...0f039a0 - tonistiigi/fsutil#66 copy: add fast copy path for darwin - tonistiigi/fsutil#67 Treat Unix sockets as regular files - relates to moby/buildkit#1144 Fix socket handling - tonistiigi/fsutil#68 fix gocrypto commit - tonistiigi/fsutil#69 receive: use filter on receive diff - prevents incremental transfers with userns because the metadata on disk is always different than the one being transferred. Signed-off-by: Sebastiaan van Stijn <[email protected]> Upstream-commit: 94a8c8b3c09540497f6fb7a3d40de80610c920ac Component: engine
Signed-off-by: Tonis Tiigi [email protected]