Hello Syncthing ppl,
I am wondering if it would be possible to set up a share in syncthing, so that:
- whenever I drop a file in it in machine A, that file gets synched to machine B
- after the file has been copied to machine B, it gets deleted from A
thats it, a true drop box
I am sorry if this is really easy to do and maybe is a well estabilished feature
Someone will correct me if I’m wrong, but I don’t think so.
You might want to check out a nice open source utility called Rclone.
It can do exactly what you want. It has a move feature that will move files from server A to server B. It doesn’t have a real time sync feature so you will need to run it at a timed interval like every hour, or however often you want it to run. It is supported on Windows, Linux, Mac, and Android, and you would use the specific operating systems automation features to run the program. On Android the program can be scheduled. The Android version is located at Github and is called Round-sync.
On windows you would use Windows Task Scheduler and on Linux you would use cron or another program that might be provided by your specific distribution.
rclone (move or moveto) source: destination:
51 providers are supported.
To sync files this way, e.g. between phone and PC, I recommend a simple script to do that
Folder A: main folder (e.g. photos)
Folder B: archive
- I always have all files synced to PC (from A)
- if I need space on my phone, I just move the photos to B
- on PC I have a simple script that runs every day and moves photos outside of B
- Syncthing detects changes and deletes on phone
You could just use one folder (A) and a script on PC that moves files (e.g. older than 1 year) outside of A. With my setup I have more flexibility which files to keep on phone.