This is how I have mine set up...
First things first, get rclone. I use fatdog, it is available in gslapt. You can simply download it from www.rclone.org and extract the rclone executable. It will run on it's own, or you can put it in /usr/lib so that it runs from anywhere.
Open a terminal and run
Code: Select all
rclone config
Code: Select all
n
Code: Select all
give it a name you would like to use, eg gdrive
Code: Select all
drive
Code: Select all
enter
The next question is scope, I pressed 1 for full access. You can do what you like.
Enter 2 more times
Edit advanced config?
Code: Select all
n
Code: Select all
y
Back to terminal. It will ask if this is to be set up as a team drive. Probably not, so
Code: Select all
n
Code: Select all
y
Code: Select all
q
I created a folder called "cloud" and then a subfolder for gdrive, onedrive & dropbox respectively (you can create a folder for whatever remote drive you have). Furthermore, you can create subfolders to have multiple accounts in each drive. I have a personal and work google drive, so the path to mine has /root/gdrive/work & /root/gdrive/personal These folders will be used as mount points.
To mount your drive you can use a couple of options. The fastest seems to be
Code: Select all
rclone mount gdrive: ~/cloud/gdrive
Alternatively, you can use this code. I use this one so I can edit libreoffice documents. It allows LO to create a temp file whilst editing your documents.
Code: Select all
rclone --vfs-cache-mode writes mount "gdrive": ~/cloud/gdrive
Code: Select all
#!/bin/sh
sleep 20
rclone --vfs-cache-mode writes mount "gdrive": ~/cloud/gdrive
Of course you can set up your own locations, names and mount points to suit yourself, but the process as above works for me.
You can repeat the same process for OneDrive, DropBox and any of the multitude of other remotes it supports. For more info on rclone, see here:
http://www.rclone.org