1 |
class bugzilla { |
class bugzilla { |
2 |
|
|
3 |
$bugzilla_location = "/usr/share/bugzilla/template/en/custom" |
$bugzilla_location = '/usr/share/bugzilla/template/en/custom' |
4 |
|
|
5 |
package { ['bugzilla', |
package {['bugzilla', |
6 |
'graphviz', |
'graphviz', |
7 |
'perl-Template-GD', # needed for graphical_report suppo |
'perl-Template-GD', # needed for graphical_report support |
8 |
'perl-Test-Taint', |
'perl-Test-Taint', |
9 |
'perl-JSON-RPC']: } |
'perl-JSON-RPC']: } |
10 |
|
|
11 |
$pgsql_password = extlookup("bugzilla_pgsql",'x') |
$pgsql_password = extlookup('bugzilla_pgsql','x') |
12 |
$ldap_password = extlookup("bugzilla_ldap",'x') |
$ldap_password = extlookup('bugzilla_ldap','x') |
13 |
|
|
14 |
postgresql::remote_db_and_user { 'bugs': |
postgresql::remote_db_and_user { 'bugs': |
15 |
description => "Bugzilla database", |
description => 'Bugzilla database', |
16 |
password => $pgsql_password, |
password => $pgsql_password, |
17 |
} |
} |
18 |
|
|
19 |
file { '/etc/bugzilla/localconfig': |
file { '/etc/bugzilla/localconfig': |
20 |
group => apache, |
group => 'apache', |
21 |
mode => 640, |
mode => '0640', |
22 |
content => template("bugzilla/localconfig"), |
content => template('bugzilla/localconfig'), |
23 |
require => Package[bugzilla], |
require => Package['bugzilla'], |
24 |
} |
} |
25 |
|
|
26 |
|
|
27 |
file { '/var/lib/bugzilla/params': |
file { '/var/lib/bugzilla/params': |
28 |
group => apache, |
group => 'apache', |
29 |
mode => 640, |
mode => '0640', |
30 |
content => template("bugzilla/params"), |
content => template('bugzilla/params'), |
31 |
require => Package[bugzilla], |
require => Package['bugzilla'], |
32 |
} |
} |
33 |
|
|
34 |
apache::webapp_other{"bugzilla": |
apache::webapp_other { 'bugzilla': |
35 |
webapp_file => "bugzilla/webapp_bugzilla.conf", |
webapp_file => 'bugzilla/webapp_bugzilla.conf', |
36 |
} |
} |
37 |
|
|
38 |
$bugs_vhost = "bugs.$domain" |
$bugs_vhost = "bugs.$::domain" |
39 |
$vhost_root = "/usr/share/bugzilla/www" |
$vhost_root = '/usr/share/bugzilla/www' |
40 |
|
|
41 |
apache::vhost_redirect_ssl { "$bugs_vhost": } |
apache::vhost_redirect_ssl { $bugs_vhost: } |
42 |
|
|
43 |
apache::vhost_base { "$bugs_vhost": |
apache::vhost_base { $bugs_vhost: |
44 |
aliases => { "/bugzilla/" => $vhost_root }, |
aliases => { '/bugzilla/' => $vhost_root }, |
45 |
use_ssl => true, |
use_ssl => true, |
46 |
location => $vhost_root, |
location => $vhost_root, |
47 |
vhost => $bugs_vhost, |
vhost => $bugs_vhost, |
48 |
} |
} |
49 |
|
|
50 |
subversion::snapshot { $bugzilla_location: |
subversion::snapshot { $bugzilla_location: |
51 |
source => "svn://svn.mageia.org/svn/web/templates/bugzilla/trunk", |
source => 'svn://svn.mageia.org/svn/web/templates/bugzilla/trunk', |
52 |
require => Package[bugzilla], |
require => Package['bugzilla'], |
53 |
} |
} |
54 |
|
|
55 |
file { "custom": |
file { 'custom': |
56 |
path => "/usr/share/bugzilla/template/en/custom", |
ensure => directory, |
57 |
ensure => directory, |
path => '/usr/share/bugzilla/template/en/custom', |
58 |
group => apache, |
group => 'apache', |
59 |
mode => 640, |
mode => '0640', |
60 |
recurse => true, |
recurse => true, |
61 |
require => Subversion::Snapshot[$bugzilla_location], |
require => Subversion::Snapshot[$bugzilla_location], |
62 |
} |
} |