diff --git a/pkg/etcd/etcd.go b/pkg/etcd/etcd.go index 491da17796..160a0efe71 100644 --- a/pkg/etcd/etcd.go +++ b/pkg/etcd/etcd.go @@ -316,10 +316,10 @@ func (e *ETCD) setName(force bool) error { return err } e.name = strings.SplitN(h, ".", 2)[0] + "-" + uuid.New().String()[:8] - if err := os.MkdirAll(filepath.Dir(fileName), 0755); err != nil { + if err := os.MkdirAll(filepath.Dir(fileName), 0700); err != nil { return err } - return ioutil.WriteFile(fileName, []byte(e.name), 0655) + return ioutil.WriteFile(fileName, []byte(e.name), 0600) } else if err != nil { return err }