diff --git a/api/file/file.go b/api/file/file.go index c9ad71a4a..63837d525 100644 --- a/api/file/file.go +++ b/api/file/file.go @@ -34,12 +34,14 @@ func NewService(dataStorePath, fileStorePath string) (*Service, error) { fileStorePath: path.Join(dataStorePath, fileStorePath), } - err := createDirectoryIfNotExist(dataStorePath, 0755) - if err != nil { - return nil, err - } + // Checking if a mount directory exists is broken with Go on Windows. + // This will need to be reviewed after the issue has been fixed in Go. + // err := createDirectoryIfNotExist(dataStorePath, 0755) + // if err != nil { + // return nil, err + // } - err = service.createDirectoryInStoreIfNotExist(TLSStorePath) + err := service.createDirectoryInStoreIfNotExist(TLSStorePath) if err != nil { return nil, err } diff --git a/build/windows/microsoftservercore/Dockerfile b/build/windows/microsoftservercore/Dockerfile index dfcd8b15a..5d67a2899 100644 --- a/build/windows/microsoftservercore/Dockerfile +++ b/build/windows/microsoftservercore/Dockerfile @@ -2,7 +2,7 @@ FROM microsoft/windowsservercore COPY dist / -VOLUME C:\\data +VOLUME C:\\ProgramData\\Portainer WORKDIR / diff --git a/build/windows/nanoserver/Dockerfile b/build/windows/nanoserver/Dockerfile index ae8a25a39..7855cba8e 100644 --- a/build/windows/nanoserver/Dockerfile +++ b/build/windows/nanoserver/Dockerfile @@ -2,7 +2,7 @@ FROM microsoft/nanoserver COPY dist / -VOLUME C:\\data +VOLUME C:\\ProgramData\\Portainer WORKDIR /