/[adm]/puppet/modules/git/manifests/init.pp
ViewVC logotype

Diff of /puppet/modules/git/manifests/init.pp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2668 by misc, Thu Mar 22 10:47:02 2012 UTC revision 2669 by misc, Thu Mar 22 10:47:04 2012 UTC
# Line 35  class git { Line 35  class git {
35          }          }
36      }      }
37    
     class client inherits common {  
   
   
     }  
   
     class svn inherits client {  
         package { 'git-svn': }  
     }  
   
     define snapshot($source, $refresh ='*/5', $user = 'root') {  
         include git::client  
         #TODO  
         # should handle branch -> clone -n + branch + checkout  
         # create a script  
         # Idealy, should be handled by vcsrepo https://github.com/bruce/puppet-vcsrepo  
         # once it is merged in puppet  
         exec { "/usr/bin/git clone $source $name":  
             creates => $name,  
             user    => $user  
         }  
   
         cron { "update $name":  
             # FIXME no -q ?  
             command => "cd $name && /usr/bin/git pull",  
             user    => $user,  
             minute  => $refresh  
         }  
     }  
38  }  }

Legend:
Removed from v.2668  
changed lines
  Added in v.2669

  ViewVC Help
Powered by ViewVC 1.1.30