diff options
Diffstat (limited to 'modules/bcd')
| -rw-r--r-- | modules/bcd/manifests/base.pp | 2 | ||||
| -rw-r--r-- | modules/bcd/manifests/init.pp | 2 | ||||
| -rw-r--r-- | modules/bcd/manifests/rsync.pp | 6 | ||||
| -rw-r--r-- | modules/bcd/manifests/web.pp | 10 | ||||
| -rw-r--r-- | modules/bcd/templates/htpasswd | 2 | ||||
| -rw-r--r-- | modules/bcd/templates/rsyncd.conf | 2 | ||||
| -rw-r--r-- | modules/bcd/templates/sudoers.bcd | 4 | ||||
| -rw-r--r-- | modules/bcd/templates/vhost_bcd.conf | 4 |
8 files changed, 13 insertions, 19 deletions
diff --git a/modules/bcd/manifests/base.pp b/modules/bcd/manifests/base.pp index 8bee2907..d515f3e1 100644 --- a/modules/bcd/manifests/base.pp +++ b/modules/bcd/manifests/base.pp @@ -1,6 +1,6 @@ class bcd::base { include sudo - include bcd + include bcd group { $bcd::login: } diff --git a/modules/bcd/manifests/init.pp b/modules/bcd/manifests/init.pp index 81f0ef1c..1ff57144 100644 --- a/modules/bcd/manifests/init.pp +++ b/modules/bcd/manifests/init.pp @@ -1,5 +1,5 @@ class bcd { $login = 'bcd' $home = '/home/bcd' - $public_isos = "$home/public_html/isos" + $public_isos = "${home}/public_html/isos" } diff --git a/modules/bcd/manifests/rsync.pp b/modules/bcd/manifests/rsync.pp index 7b772b24..0a9ccc34 100644 --- a/modules/bcd/manifests/rsync.pp +++ b/modules/bcd/manifests/rsync.pp @@ -1,7 +1,7 @@ class bcd::rsync { include bcd::base $public_isos = $bcd::public_isos - class { rsyncd: - rsyncd_conf => 'bcd/rsyncd.conf', - } + class { 'rsyncd': + rsyncd_conf => 'bcd/rsyncd.conf', + } } diff --git a/modules/bcd/manifests/web.pp b/modules/bcd/manifests/web.pp index abfa5647..d670cf5d 100644 --- a/modules/bcd/manifests/web.pp +++ b/modules/bcd/manifests/web.pp @@ -1,15 +1,9 @@ class bcd::web { include bcd::base - $location = "$bcd::home/public_html" + $location = "${bcd::home}/public_html" - apache::vhost::base { "bcd.$::domain": + apache::vhost::base { "bcd.${::domain}": location => $location, content => template('bcd/vhost_bcd.conf'), } - - # not sure if that's useful, since the file is public and trivially - # bruteforced - file { "$bcd::home/htpasswd": - content => template('bcd/htpasswd') - } } diff --git a/modules/bcd/templates/htpasswd b/modules/bcd/templates/htpasswd deleted file mode 100644 index 457a13a7..00000000 --- a/modules/bcd/templates/htpasswd +++ /dev/null @@ -1,2 +0,0 @@ -valstar:42Mx5EawIqVTY - diff --git a/modules/bcd/templates/rsyncd.conf b/modules/bcd/templates/rsyncd.conf index 26197765..75c7d335 100644 --- a/modules/bcd/templates/rsyncd.conf +++ b/modules/bcd/templates/rsyncd.conf @@ -4,7 +4,7 @@ uid = nobody gid = nogroup [isos] - path = <%= public_isos %> + path = <%= scope.lookupvar("bcd::public_isos") %> comment = Mageia ISOs exclude = .htaccess .htpasswd read only = yes diff --git a/modules/bcd/templates/sudoers.bcd b/modules/bcd/templates/sudoers.bcd index b768f653..c462bffd 100644 --- a/modules/bcd/templates/sudoers.bcd +++ b/modules/bcd/templates/sudoers.bcd @@ -3,6 +3,8 @@ /usr/sbin/urpmi, \ /usr/sbin/urpmi.addmedia, \ /usr/sbin/urpmi.removemedia, \ +/usr/sbin/urpmi.update, \ +/usr/bin/urpmq, \ /bin/rm -%<%= isomakers_group %> ALL=(<%= scope.lookupvar('bcd::login') %>) SETENV: NOPASSWD: ALL +%<%= @isomakers_group %> ALL=(<%= scope.lookupvar('bcd::login') %>) SETENV: NOPASSWD: ALL diff --git a/modules/bcd/templates/vhost_bcd.conf b/modules/bcd/templates/vhost_bcd.conf index 536b09d5..c89955e2 100644 --- a/modules/bcd/templates/vhost_bcd.conf +++ b/modules/bcd/templates/vhost_bcd.conf @@ -1,8 +1,8 @@ -<Directory <%= location %>> +<Directory <%= @location %>> AuthUserFile <%= scope.lookupvar('bcd::home') %>/htpasswd AuthGroupFile /dev/null AuthName "QA test isos, restricted access" - ErrorDocument 403 "For the password, please contact the QA team ( http://wiki.<%= domain %>/en/QA_Team )" + ErrorDocument 403 "For the password, please contact the QA team ( https://wiki.<%= @domain %>/en/QA_Team )" AuthType Basic require valid-user |
