Rclone mount in windows docker

What is the problem you are having with rclone?

Hello,

I'm having trouble mounting a S3 bucket with rclone inside a windows docker. I'm running the commands above.
To configure my docker, I copied rclone binaries and also installed winfsd and sshfs-win.
The weird thing is that the exact same commands works perfectly on my windows host.
I'm running the docker with docker run -it --rm to get command line access and try to run this mounting thing. Of course, in the end I'll simply add the commands to the docker build.

What is your rclone version (output from rclone version)

1.54.0

Which OS you are using and how many bits (eg Windows 7, 64 bit)

Windows 10, 64bits, with dockerized windows 10.

Which cloud storage system are you using? (eg Google Drive)

S3 (minio)

The command you were trying to run (eg rclone copy /tmp remote:tmp)

I first run during docker build

rclone config create dependencies_drive s3 provider Minio access_key_id <******> secret_access_key <*********> endpoint http://192.168.0.31:9000 

whichs runs fine. To be sure of this, i run

rclone tree dependencies_drive:

which also runs fine and displays the content of the bucket.
In the end, I execute

mkdir C:\users\public\Developpement
rclone.exe mount dependencies_drive: C:/users/public/Developpement/Dependencies

And I get the error :

2021/03/02 17:02:39 ERROR : S3 root: Mount failed
2021/03/02 17:02:39 Fatal error: failed to mount FUSE fs: mount stopped before calling Init: mount failed

I also tried to launch this command after docker build, during an interactive run (docker run -it --rm ).

The rclone config contents with secrets removed.

The config is created dynamically in the previous command line.

A log from the command with the -vv flag

2021/03/02 17:11:07 DEBUG : Creating backend with remote "dependencies_drive:"
2021/03/02 17:11:07 DEBUG : Using config file from "C:\\Users\\ContainerAdministrator\\.config\\rclone\\rclone.conf"
2021/03/02 17:11:07 INFO  : S3 root: poll-interval is not supported by this remote
2021/03/02 17:11:07 DEBUG : Network mode mounting is disabled
2021/03/02 17:11:07 DEBUG : Mounting on "c:/users/public/Dependencies" ("dependencies_drive")
2021/03/02 17:11:07 DEBUG : S3 root: Mounting with options: ["-o" "attr_timeout=1" "-o" "uid=-1" "-o" "gid=-1" "--FileSystemName=rclone" "-o" "volname=dependencies_drive"]
2021/03/02 17:11:07 ERROR : S3 root: Mount failed
2021/03/02 17:11:07 Fatal error: failed to mount FUSE fs: mount stopped before calling Init: mount failed

Thank you for reading :slight_smile:

Which WinFSP are you using?

According to https://github.com/billziss-gh/winfsp/issues/258 you will need at least WinFSP 2020.2 for windows container support.

Hello, and thank you aking the time,

I use WinFSP 1.8 which is 2020.2 according to their website.

However the link you provided is very interesting -- it drove me to https://github.com/billziss-gh/winfsp/wiki/WinFsp-Container-Support

I concluded two things :

  • List item I changed my windows image to a servercore one
  • List item I need to run my docker with --isolation=process (which does not work)
  • List item I need to hardcode a registery key inside windows? But this is not well documented.

I'll also try with WinFSP 2021 beta, at this point it's worth trying everything :slight_smile:

1 Like

Good luck! If you can't get it to work it might be worth making an issue on the WinFSP site

It's not working with the beta either. Continuing my investigation....

1 Like

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.