Created
October 27, 2014 14:34
-
-
Save Skinner927/207e9febf1e0b8489f4a to your computer and use it in GitHub Desktop.
Upstart job for sshfs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
start on (local-filesystems and net-device-up IFACE!=lo) | |
task | |
script | |
echo "start on: $(date)" > /home/user/automount_log.txt | |
while true; do ping -c1 172.16.76.50 &> /dev/null && break; done | |
sshfs -o allow_other,uid=$(id -u),gid=$(id -g),delay_connect [email protected]:user/git/website-user/ /var/www/website_user >> /home/user/automount_log.txt 2>&1 | |
echo "end on: $(date)" >> /home/user/automount_log.txt | |
end script |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://github.com/axkibe/lsyncd is another alternative