xer0x / triton-syncthing-cluster

Syncthing cluster blueprint for a Docker Container on Triton using Consul and Compose

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

triton-syncthing-cluster

A Dockerized Syncthing Compose script for use on Joyent's Triton infrastructure. It uses Consul to share configuration and discover the IPs of other Syncthing devices.

Syncthing is let's you setup DIY Dropbox-like folders that stay in sync with each other. This can be useful for tasks that you might normally use docker --volumes for. Specific usage examples include backups, exporting configuration files, and syncing user uploads between servers. Basically this is ideal for situations where files are seldom written, and it's okay if changes take upto a minute to propagate to other containers. Also this works well for syncing content between web servers since reads are quick because the files are on local storage

For this to work you'll need to already have setup Docker, Docker-compose, and a Joyent Triton account.

# The simple way
bash start.sh

or

# The detailed way

# Start up Consul and Syncthing
docker-compose --project-name=stc up -d --timeout=300

# Scale up more Syncthing containers
docker-compose --project-name=stc scale syncthing=4

This script is intended for Joyent Triton. It expects each Syncthing container to have its own unique IP address. These containers should be able to run on any Docker compatible infrastruture that gives each container an IP address to avoid exposed port collisions. View the xer0x/triton-syncthing image for more details.

About

Syncthing cluster blueprint for a Docker Container on Triton using Consul and Compose


Languages

Language:Shell 100.0%