summaryrefslogtreecommitdiff
path: root/doc/special_remotes/rsync.mdwn
blob: 273469258b341a6939e0f67460b3d36bb3c058c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
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 in rsync, 
  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. 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 or `hostname:/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 if `git 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.