Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: modules/filtermaster/manifests/repo_download.pp

Issue 29329102: Issue 3091 - Integrate contentblockerlists with Puppet (Closed)
Patch Set: Created Oct. 13, 2015, 4:17 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « modules/filtermaster/manifests/init.pp ('k') | modules/filtermaster/templates/sshd_rsync.erb » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # == Type: filtermaster::repo_download 1 # == Type: filtermaster::repo_download
2 # 2 #
3 # Manage filter list download source repositories for aggregation. 3 # Manage filter list download source repositories for aggregation.
4 # 4 #
5 # === Parameters: 5 # === Parameters:
6 # 6 #
7 # [*target*] 7 # [*target*]
8 # An optional alias for use as the download resource name, allows for 8 # An optional alias for use as the download resource name, allows for
9 # repositories with different names. Note that this option is recognized 9 # repositories with different names. Note that this option is recognized
10 # only when setup via hiera('filtermaster::repo_downloads')! 10 # only when setup via hiera('filtermaster::repo_downloads')!
11 # 11 #
12 # [*static_files*]
13 # Files to include in the synchronization of download resources without
14 # prior aggregation, if any. Note that option is recognized only when
15 # setup via hiera('filtermaster::repo_downloads') as well!
16 #
12 # === Examples: 17 # === Examples:
13 # 18 #
14 # filtermaster::repo_download {'exceptionrules': 19 # filtermaster::repo_download {'exceptionrules':
15 # alias => 'exceptions', 20 # alias => 'exceptions',
16 # } 21 # }
17 # 22 #
18 define filtermaster::repo_download ( 23 define filtermaster::repo_download (
19 $target = $title, 24 $target = $title,
25 $static_files = [],
20 ) { 26 ) {
21 27
22 $directory = "/home/rsync/subscription/$title" 28 $directory = "/home/rsync/subscription/$title"
23 $repository = "https://hg.adblockplus.org/$title" 29 $repository = "https://hg.adblockplus.org/$title"
24 30
25 ensure_packages(['mercurial']) 31 ensure_packages(['mercurial'])
26 32
27 exec {"filtermaster::repo_download#$title": 33 exec {"filtermaster::repo_download#$title":
28 command => shellquote('hg', 'clone', $repository, $directory), 34 command => shellquote('hg', 'clone', $repository, $directory),
29 onlyif => shellquote('test', '!', '-d', $directory), 35 onlyif => shellquote('test', '!', '-d', $directory),
30 path => ['/usr/local/bin', '/usr/bin', '/bin'], 36 path => ['/usr/local/bin', '/usr/bin', '/bin'],
31 require => Package['mercurial'], 37 require => Package['mercurial'],
32 timeout => 0, 38 timeout => 0,
33 user => 'rsync', 39 user => 'rsync',
34 } 40 }
35 } 41 }
OLDNEW
« no previous file with comments | « modules/filtermaster/manifests/init.pp ('k') | modules/filtermaster/templates/sshd_rsync.erb » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld