fix: remove full access permissions (#11261)
This commit is contained in:
parent
453e276718
commit
a8ed6fd192
|
|
@ -183,7 +183,7 @@ func createTestFiles(dir string, st *SockTest) error {
|
||||||
writeFile := func(prefix string, i int) error {
|
writeFile := func(prefix string, i int) error {
|
||||||
f := sockFile(prefix, i)
|
f := sockFile(prefix, i)
|
||||||
fpath := filepath.Join(dir, f)
|
fpath := filepath.Join(dir, f)
|
||||||
return os.WriteFile(fpath, []byte(""), 0777)
|
return os.WriteFile(fpath, []byte(""), 0644)
|
||||||
}
|
}
|
||||||
return tstFileApply(st, writeFile)
|
return tstFileApply(st, writeFile)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -316,7 +316,7 @@ func (monitor *DirectoryMonitor) Init() error {
|
||||||
|
|
||||||
// Finished directory can be created if not exists for convenience.
|
// Finished directory can be created if not exists for convenience.
|
||||||
if _, err := os.Stat(monitor.FinishedDirectory); os.IsNotExist(err) {
|
if _, err := os.Stat(monitor.FinishedDirectory); os.IsNotExist(err) {
|
||||||
err = os.Mkdir(monitor.FinishedDirectory, 0777)
|
err = os.Mkdir(monitor.FinishedDirectory, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
@ -328,7 +328,7 @@ func (monitor *DirectoryMonitor) Init() error {
|
||||||
// If an error directory should be used but has not been configured yet, create one ourselves.
|
// If an error directory should be used but has not been configured yet, create one ourselves.
|
||||||
if monitor.ErrorDirectory != "" {
|
if monitor.ErrorDirectory != "" {
|
||||||
if _, err := os.Stat(monitor.ErrorDirectory); os.IsNotExist(err) {
|
if _, err := os.Stat(monitor.ErrorDirectory); os.IsNotExist(err) {
|
||||||
err := os.Mkdir(monitor.ErrorDirectory, 0777)
|
err := os.Mkdir(monitor.ErrorDirectory, 0755)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue