mirror of https://github.com/k3s-io/k3s
Merge pull request #38801 from nak3/nfs-mkdir
Automatic merge from submit-queue Catch error when failed to make directory in NFS volume plugin NFS: Catch error when failed to make directory Currently, NFS volume plugin doesn't catch the error from os.MkdirAll. That makes it difficult to debug why failed to make the directory. This patch adds error catch to os.MkdirAll.pull/6/head
commit
854441643f
|
@ -246,7 +246,9 @@ func (b *nfsMounter) SetUpAt(dir string, fsGroup *int64) error {
|
|||
if !notMnt {
|
||||
return nil
|
||||
}
|
||||
os.MkdirAll(dir, 0750)
|
||||
if err := os.MkdirAll(dir, 0750); err != nil {
|
||||
return err
|
||||
}
|
||||
source := fmt.Sprintf("%s:%s", b.server, b.exportPath)
|
||||
options := []string{}
|
||||
if b.readOnly {
|
||||
|
|
Loading…
Reference in New Issue