Last active
August 29, 2015 14:05
-
-
Save mowings/7231988a2fd6ee7089d0 to your computer and use it in GitHub Desktop.
rsync as sudo-ed user on the remote host. Needed to preserve permissions, get special files over, etc
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
# Remote user must have NOPASSWD set in sudoers | |
# This example mirrors an entire directory | |
rsync --progress -avz --delete --rsync-path="sudo rsync" /path/to/sync/ user@host:/path/to/sync |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment