diff options
author | Colin Guthrie <colin@mageia.org> | 2014-03-23 16:19:35 +0000 |
---|---|---|
committer | Colin Guthrie <colin@mageia.org> | 2014-03-23 16:19:35 +0000 |
commit | 29b4c8338ac752d88297a8383405d911ad0343c1 (patch) | |
tree | 2785bbd40783066ee7faf157b89ab0e300ac4615 | |
parent | fd483f00e72c484344e93d3b6ec9294a526fb891 (diff) | |
download | puppet-29b4c8338ac752d88297a8383405d911ad0343c1.tar puppet-29b4c8338ac752d88297a8383405d911ad0343c1.tar.gz puppet-29b4c8338ac752d88297a8383405d911ad0343c1.tar.bz2 puppet-29b4c8338ac752d88297a8383405d911ad0343c1.tar.xz puppet-29b4c8338ac752d88297a8383405d911ad0343c1.zip |
Support git snapshots of a specific branch name (needed for identity.mageia.org)
-rw-r--r-- | modules/git/manifests/snapshot.pp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/modules/git/manifests/snapshot.pp b/modules/git/manifests/snapshot.pp index 47ace403..940b50f0 100644 --- a/modules/git/manifests/snapshot.pp +++ b/modules/git/manifests/snapshot.pp @@ -1,6 +1,7 @@ define git::snapshot( $source, $refresh = '*/5', - $user = 'root') { + $user = 'root', + $branch = 'master') { include git::client #TODO # should handle branch -> clone -n + branch + checkout @@ -8,7 +9,7 @@ define git::snapshot( $source, # 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": + exec { "/usr/bin/git clone -b $branch $source $name": creates => $name, user => $user } |