Skip to content

Commit e2c9b92

Browse files
authored
Merge pull request #2464 from actiontech/up_pidfile_permission
fix: up pidfile dir permission
2 parents eef2294 + 5609dea commit e2c9b92

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sqle/driver/plugin_manager.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ func (pm *pluginManager) Start(pluginDir string, pluginConfigList []config.Plugi
183183
// kill plugins process residual and remove pidfile
184184
var wg sync.WaitGroup
185185
dir := GetPluginPidDirPath(pluginDir)
186-
if err := os.MkdirAll(dir, 0644); err != nil {
186+
if err := os.MkdirAll(dir, 0755); err != nil {
187187
return err
188188
}
189189
if err := filepath.Walk(dir, func(path string, info os.FileInfo, err error) error {
@@ -369,7 +369,7 @@ func GetPluginPidFilePath(pluginDir string, pluginName string) string {
369369
}
370370

371371
func WritePidFile(pidFilePath string, pid int64) error {
372-
if err := os.MkdirAll(filepath.Dir(pidFilePath), 0644); err != nil {
372+
if err := os.MkdirAll(filepath.Dir(pidFilePath), 0755); err != nil {
373373
return err
374374
}
375375
file, err := os.OpenFile(pidFilePath, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, 0644)

0 commit comments

Comments
 (0)