Syncthing Peer to Peer file syncing


Image: https://www.idiria.com/alternativa-dropbox-gratis


What

A way to sync folders between computers.
Computers don't need to be directly connected to sync.


No need to be directly connected?

  1. Computers are defined by crytographic ids
  2. Folders to be synced are referenced with this ids
  3. You can sync files in between more than two instances
  4. If an instance you trust is carrying a previously synced folder from another instance you trust, you can sync them too

file syncing? Isn't that backup?

It makes an exact copy, so it doesn't save you from yourself.
If you erase a file in one device, it will eventually dissapear from all.

You can tune this although


How

  1. each computer runs an instance
  2. whenever they are connected
  3. they sync: check what changed, and exchange that

How do they connect


Over any local network

Instances find each other, no manual task needed.
If they are in the same (wifi) network, they will sync.


Over the internet directly

If one of them is a server, another instance can connect directly


Over the internet through relays

There is a network of computers (relays) that helps instances to connect.


What do they sync

  1. you define resources to be synced

Devices I have it running

  • my phone, using Syncthing-fork
  • my partner's phone
  • My personal computer
  • Home server: A single board computer running 24/7 at home

Usecases


Notes: Obsidian

They are synced in between my phone, my personal computer and a small server at home.


Passwords: KeePassXC

https://keepassxc.org/

The program is running in my phone and in my personal computer.
It also backups to my Home server.


Photos

Both of our phones share the phone photo folder, and they only sync with the Home server, so we have a second copy. We can safely remove photos from our phones to make space for new ones.

This deals with phone theft.

Workflow for post-processing them is still in the works, and it doesn't contemplate the camera I have.


Music

Have it synced between computer, phone and Home server.


Accountancy

I started using hledger to keep my books.
I input my expenses using cone on my mobile phone.

I then do conciliations and further inputs in my computer, directly on the file or using hledger-ui.


GPS Tracks

I've been recording my RV trips using Trackbook.

I keep a copy of this in my Home server.


Anything that uses files as a storage mechanism can be synced using Syncthing:

  • emails
  • RSS
  • passing files between phone and computer (no sending over telegram anymore)

Syncthing context overview

https://delftswa.gitbooks.io/desosa-2017/content/syncthing/chapter.html

https://delftswa.gitbooks.io/desosa-2017/content/syncthing/chapter.html


References:

These are links I've found useful through my journey into synthing:

Select a repo