Skip to content

Commit

Permalink
fix: lazy close file store (oras-project#831)
Browse files Browse the repository at this point in the history
Fixes oras-project#815 
We should delete the temp file after pulling the image to reduce storage
usage

Signed-off-by: Chi Qin <[email protected]>
  • Loading branch information
chi-qin authored Feb 21, 2023
1 parent e8acf71 commit 1deed1c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions cmd/oras/pull.go
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ func runPull(opts pullOptions) error {
if err != nil {
return err
}
defer dst.Close()
dst.AllowPathTraversalOnWrite = opts.PathTraversal
dst.DisableOverwrite = opts.KeepOldFiles

Expand Down

0 comments on commit 1deed1c

Please sign in to comment.