I was trying to use rclone to backup my images to google drive from rpi.
Code: Select all
rclone -v move /home/pi/Desktop/Project/html_server/picturestaken remote:rclone --delete-after --include *.jpg --include *.log
Code: Select all
2018/02/10 00:51:18 INFO : Google drive root 'rclone': Modify window is 1ms
2018/02/10 00:51:19 INFO : Google drive root 'rclone': Waiting for checks to finish
2018/02/10 00:51:19 INFO : Google drive root 'rclone': Waiting for transfers to finish
2018/02/10 00:51:22 INFO : ThirdEye_2018_02_09_19_03_35.jpg: Copied (new)
2018/02/10 00:51:22 INFO : ThirdEye_2018_02_09_19_03_35.jpg: Deleted
2018/02/10 00:51:23 INFO : ThirdEye_2018_02_09_18_40_00.jpg: Copied (new)
2018/02/10 00:51:23 INFO : ThirdEye_2018_02_09_18_40_00.jpg: Deleted
2018/02/10 00:51:23 INFO : ThirdEye_2018_02_09_19_47_19.jpg: Copied (new)
2018/02/10 00:51:23 INFO : ThirdEye_2018_02_09_19_47_19.jpg: Deleted
2018/02/10 00:51:24 INFO : ThirdEye_2018_02_09_19_00_24.jpg: Copied (new)
2018/02/10 00:51:24 INFO : ThirdEye_2018_02_09_19_00_24.jpg: Deleted
2018/02/10 00:51:24 INFO :
Transferred: 83.274 kBytes (8.205 kBytes/s)
Errors: 0
Checks: 4
Transferred: 4
Elapsed time: 10.1s
But when i try to include above rclone command with my django application it fails to find rcone.conf.
I have used this weblink as a guide for rclone set-up.
https://www.hackster.io/uladzislau-bayo ... ted-048422
But there are two warnings in the guide:
Code: Select all
IMPORTANT:
Please keep in mind there can be new storage types under "Type of storage to configure" step, so just double check you select right cloud type.
If you are going to call rclone from other application you need to copy rclone.config to the .config folder under application's root and assign owner and group to it same as application uses:
Code: Select all
sudo mkdir -p /SOME_APP/.config/rclone
sudo cp /home/pi
sudo chown -R some_owner:some_group /SOME_APP/.config
I tried the first command :
It created a directory in "/" directory as
Code: Select all
/html_server/.config/rclone
It gave me as no destination directory.
so i manually copied "rclone.conf" file to the newly created ".config" directory.
then i ran the third command:
Code: Select all
sudo chown -R pi:pi /html_server/.config
It gives me an error as
Code: Select all
2018/02/09 19:47:46 NOTICE: Config file "/root/.config/rclone/rclone.conf" not found - using defaults
2018/02/09 19:47:46 Failed to create file system for "remote:rclone": didn't find section in config file
Thanks