solana/net/scripts/install-rsync.sh

21 lines
307 B
Bash
Raw Normal View History

#!/usr/bin/env bash
#
# Rsync setup
#
2018-11-11 09:25:59 -08:00
set -ex
[[ $(uname) = Linux ]] || exit 1
[[ $USER = root ]] || exit 1
apt-get --assume-yes install rsync
cat > /etc/rsyncd.conf <<-EOF
[config]
path = /var/snap/solana/current/config
hosts allow = *
read only = true
EOF
systemctl enable rsync
systemctl start rsync