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