From 816b5377872d30d6b834674431a959bd8f2ec313 Mon Sep 17 00:00:00 2001 From: HFO4 <912394456@qq.com> Date: Tue, 7 Apr 2020 11:09:27 +0800 Subject: [PATCH] Fix: permission error while creating folder recursively --- pkg/filesystem/driver/local/handler.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/filesystem/driver/local/handler.go b/pkg/filesystem/driver/local/handler.go index e773773..53147a9 100644 --- a/pkg/filesystem/driver/local/handler.go +++ b/pkg/filesystem/driver/local/handler.go @@ -56,7 +56,7 @@ func (handler Driver) Put(ctx context.Context, file io.ReadCloser, dst string, s // 如果目标目录不存在,创建 basePath := filepath.Dir(dst) if !util.Exists(basePath) { - err := os.MkdirAll(basePath, 0644) + err := os.MkdirAll(basePath, 0744) if err != nil { util.Log().Warning("无法创建目录,%s", err) return err -- GitLab