|
@@ -675,14 +675,14 @@ func NewDaemon(config *config.Config, registryService registry.Service, containe
|
|
}
|
|
}
|
|
|
|
|
|
daemonRepo := filepath.Join(config.Root, "containers")
|
|
daemonRepo := filepath.Join(config.Root, "containers")
|
|
- if err := idtools.MkdirAllAndChown(daemonRepo, 0700, rootIDs); err != nil && !os.IsExist(err) {
|
|
|
|
|
|
+ if err := idtools.MkdirAllAndChown(daemonRepo, 0700, rootIDs); err != nil {
|
|
return nil, err
|
|
return nil, err
|
|
}
|
|
}
|
|
|
|
|
|
// Create the directory where we'll store the runtime scripts (i.e. in
|
|
// Create the directory where we'll store the runtime scripts (i.e. in
|
|
// order to support runtimeArgs)
|
|
// order to support runtimeArgs)
|
|
daemonRuntimes := filepath.Join(config.Root, "runtimes")
|
|
daemonRuntimes := filepath.Join(config.Root, "runtimes")
|
|
- if err := system.MkdirAll(daemonRuntimes, 0700, ""); err != nil && !os.IsExist(err) {
|
|
|
|
|
|
+ if err := system.MkdirAll(daemonRuntimes, 0700, ""); err != nil {
|
|
return nil, err
|
|
return nil, err
|
|
}
|
|
}
|
|
if err := d.loadRuntimes(); err != nil {
|
|
if err := d.loadRuntimes(); err != nil {
|
|
@@ -690,7 +690,7 @@ func NewDaemon(config *config.Config, registryService registry.Service, containe
|
|
}
|
|
}
|
|
|
|
|
|
if runtime.GOOS == "windows" {
|
|
if runtime.GOOS == "windows" {
|
|
- if err := system.MkdirAll(filepath.Join(config.Root, "credentialspecs"), 0, ""); err != nil && !os.IsExist(err) {
|
|
|
|
|
|
+ if err := system.MkdirAll(filepath.Join(config.Root, "credentialspecs"), 0, ""); err != nil {
|
|
return nil, err
|
|
return nil, err
|
|
}
|
|
}
|
|
}
|
|
}
|