]> gitweb.fluxo.info Git - puppet-git.git/commitdiff
Adding git-annex integration
authorSilvio Rhatto <rhatto@riseup.net>
Sun, 1 Sep 2013 23:30:31 +0000 (20:30 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Sun, 1 Sep 2013 23:30:31 +0000 (20:30 -0300)
files/gitolite.rc.wheezy
manifests/gitolite.pp

index a6b5da35693b65c18efb19465ae0c870e47e8521..a1dd05891f4f3373c2e372e971bc2f09ef6ff008 100644 (file)
@@ -56,6 +56,7 @@ $SVNSERVE = "";
 # $UPDATE_CHAINS_TO = "hooks/update.secondary";
 # $ADMIN_POST_UPDATE_CHAINS_TO = "hooks/post-update.secondary";
 # $GL_ADC_PATH = "";
+$GL_ADC_PATH = "/var/git/adc/";
 # $GL_GET_MEMBERSHIPS_PGM = "/usr/local/bin/expand-ldap-user-to-groups"
 # $GL_HTTP_ANON_USER = "mob";
 # $GL_REF_OR_FILENAME_PATT=qr(^[0-9a-zA-Z][0-9a-zA-Z._\@/+ :,-]*$);
index 68d655ee211a159b0bca8becd51c5a1f6c2bd0b4..a56735e614c76b61890ccaf5e0a60e41da7a7ba7 100644 (file)
@@ -104,5 +104,31 @@ class gitolite inherits git {
     ensure   => present,
     require  => File['/usr/local/sbin/git-mass-update-server-info'],
   }
+
+  # git-annex integration
+  package { 'git-annex':
+    ensure => present,
+  }
+
+  # wheezy onwards
+  # http://git-annex.branchable.com/tips/using_gitolite_with_git-annex/
+  file { [ '/var/git/adc', '/var/git/adc/ua' ]:
+    ensure  => $::lsbdistcodename ? {
+      'squeeze' => absent,
+       default  => present,
+    },
+    owner   => gitolite,
+    group   => gitolite,
+    mode    => 0755,
+    require => File['/var/git'],
+  }
+
+  exec { 'git-annex-shell-copier':
+    command => 'cp /usr/share/doc/gitolite/examples/adc/git-annex-shell /var/git/adc/ua/git-annex-shell',
+    user    => root,
+    creates => '/var/git/adc/ua/git-annex-shell',
+    onlyif  => "test -f /usr/share/doc/gitolite/examples/adc/git-annex-shell",
+    require => [ Package['git-annex'], File['/var/git/adc/ua'] ],
+  }
 }