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

Delta Between Two Patch Sets: modules/adblockplus/manifests/web/fileserver/repository.pp

Issue 29795567: #11371 - Password protection for fileserver repositories (Closed)
Left Patch Set: For comment 4 Created June 2, 2018, 9:04 p.m.
Right Patch Set: For comment 7 Created June 5, 2018, 6:47 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « modules/adblockplus/manifests/web/fileserver.pp ('k') | modules/adblockplus/templates/web/fileserver.conf.erb » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 # == Type: adblockplus::web::fileserver::repository 1 # == Type: adblockplus::web::fileserver::repository
2 # 2 #
3 # Manage a repository on a fileserver. 3 # Manage a repository on a fileserver.
4 # 4 #
5 # A repository is a site where a group of people can upload and artifacts. 5 # A repository is a site where a group of people can upload and artifacts.
6 # 6 #
7 # In its current form, a repository is simply a directory exposed on a web 7 # In its current form, a repository is simply a directory exposed on a web
8 # server. This may evolve to make use of more advanced repositories in the 8 # server. This may evolve to make use of more advanced repositories in the
9 # future (proxy to repository manager, or 3rd-party service, etc). 9 # future (proxy to repository manager, or 3rd-party service, etc).
10 # 10 #
(...skipping 27 matching lines...) Expand all
38 $auth_filename = "${::adblockplus::directory}/htpasswd/${name}" 38 $auth_filename = "${::adblockplus::directory}/htpasswd/${name}"
39 39
40 nginx::hostconfig {"$repository_host": 40 nginx::hostconfig {"$repository_host":
41 content => template("adblockplus/web/fileserver.conf.erb"), 41 content => template("adblockplus/web/fileserver.conf.erb"),
42 is_default => false, 42 is_default => false,
43 certificate => $adblockplus::web::fileserver::certificate, 43 certificate => $adblockplus::web::fileserver::certificate,
44 private_key => $adblockplus::web::fileserver::private_key, 44 private_key => $adblockplus::web::fileserver::private_key,
45 log => 'access_log_fileserver', 45 log => 'access_log_fileserver',
46 } 46 }
47 47
48 ensure_resource('file', $auth_filename, merge({ 48 if $auth_file != undef {
49 ensure => ensure_file_state($ensure), 49 ensure_resource('file', $auth_filename, merge({
50 }, $auth_file)) 50 ensure => ensure_file_state($ensure),
mathias 2018/06/05 15:02:58 This might be undef now, to indicate that there's
f.lopez 2018/06/05 18:00:44 Acknowledged.
51 }, $auth_file))
52 }
51 53
52 group {"$group_name": 54 group {"$group_name":
53 ensure => $ensure, 55 ensure => $ensure,
54 } 56 }
55 57
56 file {"$repository_directory": 58 file {"$repository_directory":
57 ensure => ensure_directory_state($ensure), 59 ensure => ensure_directory_state($ensure),
58 group => $group_name, 60 group => $group_name,
59 mode => '0775', 61 mode => '0775',
60 require => [ 62 require => [
(...skipping 10 matching lines...) Expand all
71 73
72 realize(File[$adblockplus::directory]) 74 realize(File[$adblockplus::directory])
73 75
74 file {"/var/www/$repository_host": 76 file {"/var/www/$repository_host":
75 ensure => ensure_symlink_state($ensure), 77 ensure => ensure_symlink_state($ensure),
76 target => "$repository_directory", 78 target => "$repository_directory",
77 require => File["$repository_directory"], 79 require => File["$repository_directory"],
78 } 80 }
79 } 81 }
80 82
LEFTRIGHT

Powered by Google App Engine
This is Rietveld