1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Correct perms for directory creation

Directories should be 0755, not 0644

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
This commit is contained in:
Phil Estes 2015-09-17 15:19:23 -04:00
parent 987aab8f3e
commit 437dfd3a43
2 changed files with 3 additions and 2 deletions

View file

@ -49,7 +49,7 @@ func init() {
} }
func createBasePath() { func createBasePath() {
err := os.MkdirAll(prefix, 0644) err := os.MkdirAll(prefix, 0755)
if err != nil { if err != nil {
panic("Could not create net namespace path directory") panic("Could not create net namespace path directory")
} }

View file

@ -416,6 +416,7 @@ func (sb *sandbox) clearNetworkResources(ep *endpoint) error {
const ( const (
defaultPrefix = "/var/lib/docker/network/files" defaultPrefix = "/var/lib/docker/network/files"
dirPerm = 0755
filePerm = 0644 filePerm = 0644
) )
@ -777,7 +778,7 @@ func (eh *epHeap) Pop() interface{} {
} }
func createBasePath(dir string) error { func createBasePath(dir string) error {
return os.MkdirAll(dir, filePerm) return os.MkdirAll(dir, dirPerm)
} }
func createFile(path string) error { func createFile(path string) error {