mirror of
https://github.com/rclone/rclone.git
synced 2024-11-07 09:04:52 +01:00
docker: fix volume plugin does not remount volume on docker restart
docker volume plugin restoreState: skip fs option if empty Fixes #6769 Co-authored-by: Peter Kreuser <logo@kreuser.name>
This commit is contained in:
parent
56b582cdb9
commit
5039f9be48
@ -60,12 +60,14 @@ func (vol *Volume) applyOptions(volOpt VolOpts) error {
|
||||
case "":
|
||||
continue
|
||||
case "remote", "fs":
|
||||
p, err := fspath.Parse(str)
|
||||
if err != nil || p.Name == ":" {
|
||||
return fmt.Errorf("cannot parse path %q: %w", str, err)
|
||||
if str != "" {
|
||||
p, err := fspath.Parse(str)
|
||||
if err != nil || p.Name == ":" {
|
||||
return fmt.Errorf("cannot parse path %q: %w", str, err)
|
||||
}
|
||||
fsName, fsPath, fsOpt = p.Name, p.Path, p.Config
|
||||
vol.Fs = str
|
||||
}
|
||||
fsName, fsPath, fsOpt = p.Name, p.Path, p.Config
|
||||
vol.Fs = str
|
||||
case "type":
|
||||
fsType = str
|
||||
vol.Type = str
|
||||
|
Loading…
Reference in New Issue
Block a user