From a37830383d26d3f0d07342a3a130a758059496b2 Mon Sep 17 00:00:00 2001 From: Chenqun Lu Date: Sun, 29 Oct 2023 16:32:38 +0800 Subject: [PATCH] fix(snapshot): grant execution permissions to the snapshot dir for the owner (#18294) Co-authored-by: Julien Robert --- server/util.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/util.go b/server/util.go index 17741d778993..7e028293cc21 100644 --- a/server/util.go +++ b/server/util.go @@ -537,7 +537,7 @@ func DefaultBaseappOptions(appOpts types.AppOptions) []func(*baseapp.BaseApp) { func GetSnapshotStore(appOpts types.AppOptions) (*snapshots.Store, error) { homeDir := cast.ToString(appOpts.Get(flags.FlagHome)) snapshotDir := filepath.Join(homeDir, "data", "snapshots") - if err := os.MkdirAll(snapshotDir, 0o644); err != nil { + if err := os.MkdirAll(snapshotDir, 0o744); err != nil { return nil, fmt.Errorf("failed to create snapshots directory: %w", err) }