FreeBSD - Resilio Sync

Download: https://www.resilio.com/individuals/

... auspacken und nach /usr/local/sbin schieben

# chown root:wheel /usr/local/sbin/rslsync

# chmod 555 /usr/local/sbin/rslsync

/etc/rc.conf

#Resilio Sync
rslsync_enable="YES"
#rslsync_user="root"
#rslsync_bin="/usr/local/sbin/rslsync"

/usr/local/etc/rc.d/rslsync

#!/bin/sh
#
# PROVIDE: rslsync
# REQUIRE: LOGIN DAEMON NETWORKING
# KEYWORD: shutdown
#
# To enable Resilio Sync, add this line to your /etc/rc.conf:
#
# rslsync_enable="YES"
#
# And optionally these line:
#
# rslsync_user="username" # Default is "root"
# rslsync_bin="/path/to/rslsync" # Default is "/usr/local/sbin/rslsync"

. /etc/rc.subr

name="rslsync"
rcvar="rslsync_enable"

load_rc_config $name

required_files=$rslsync_bin

: ${rslsync_enable="NO"}
: ${rslsync_user="root"}
: ${rslsync_bin="/usr/local/sbin/rslsync"}
: ${rslsync_config="/usr/local/etc/rslsync.conf"}

command=$rslsync_bin
command_args="--config ${rslsync_config}"

run_rc_command "$1"
# chmod 555 /usr/local/etc/rc.d/rslsync

rslsync.conf

eine default rslsync.conf erstellen:

# /usr/local/sbin/rslsync --dump-sample-config > /usr/local/etc/rslsync.sample.conf

meine /usr/local/etc/rslsync.conf

{

    "device_name": "cloud",
    "listening_port" : 0,
    "storage_path" : "/usr/local/etc/rslsync",
    "pid_file" : "/var/run/resilio.pid",
    "use_upnp" : true,
    "download_limit" : 0,
    "upload_limit" : 0,
    "webui" : {},

    "shared_folders" :
    [
        {
          "secret" : "",
          "dir" : "/usr/home/resilio/foobar",
          "use_relay_server" : false,
          "use_tracker" : true,
          "search_lan" : false,
          "use_sync_trash" : true,
          "overwrite_changes" : false,
          "selective_sync" : false,
          "known_hosts" : []
        }
    ]

}

die Ordner anlegen

# mkdir /usr/local/etc/rslsync

# mkdir /usr/home/resilio/foobar

Starten

# /usr/local/etc/rc.d/rslsync start