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