This special remote type rsyncs file contents to somewhere else.
Setup example:
# git annex initremote myrsync type=rsync rsyncurl=rsync://rsync.example.com/myrsync encryption=joey@kitenet.net
# git annex describe myrsync "rsync server"
Or for using rsync over SSH
# git annex initremote myrsync type=rsync rsyncurl=ssh.example.com:/myrsync encryption=joey@kitenet.net
# git annex describe myrsync "rsync server"
configuration
These parameters can be passed to git annex initremote
to configure rsync:
encryption
- Required. Either "none" to disable encryption of content stored on the remote rsync server, or a value that can be looked up (using gpg -k) to find a gpg encryption key that will be given access to the remote, or "shared" which allows every clone of the repository to decrypt the encrypted data.Note that additional gpg keys can be given access to a remote by rerunning initremote with the new key id. See encryption.
rsyncurl
- Required. This is the url orhostname:/directory
to pass to rsync to tell it where to store content.shellescape
- Optional. Set to "no" to avoid shell escaping normally done when using rsync over ssh. That escaping is needed with typical setups, but not with some hosting providers that do not expose rsynced filenames to the shell. You'll know you need this option ifgit annex get
from the special remote fails with an error message containing a single quote ('
) character. If that happens, you can re-run initremote setting shellescape=no.
The annex-rsync-options
git configuration setting can be used to pass
parameters to rsync.
Hi, I would like to see a example of setting up / using e.g. rsync.net as a repo.
Please also provide a highlevel description of how the rsync repo fits in with git-annex.
Q1. can you adds files to the remote rsync repo, and will they be detected and synced back ? Q2. is all the git history rsync'd to remote ? how do i recover if i loose all data except the remote rsync repo ?
Your comment "No, special remotes do not contain a copy of the git repository"
so a special remote is
"A. just a remote filesystem, that contains the objects with sha1 names ? "
"D. the data on the cloud/rsync storage can not be used directly it has to moved into a git-annex capable storage location. "
Would it not be better to mount the remote storage over ssh(sshfs) and then use full git-annex on mounted directory ?