Puppet Class: mailman::webui

Defined in:
modules/mailman/manifests/webui.pp

Overview

Sets up a web server to be used by mailman.



2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# File 'modules/mailman/manifests/webui.pp', line 2

class mailman::webui {

    $lists_servername = hiera('mailman::lists_servername')

    $ssl_settings = ssl_ciphersuite('apache', 'mid', true)

    httpd::site { 'lists.wikimedia.org':
        content => template('mailman/lists.wikimedia.org.erb'),
    }

    # htdigest file for private list archives
    file { '/etc/apache2/arbcom-l.htdigest':
        content   => secret('mailman/arbcom-l.htdigest'),
        owner     => 'root',
        group     => 'www-data',
        mode      => '0440',
        require   => Class['httpd'],
        show_diff => false,
    }

    # Add files in /var/www (docroot)
    file { '/var/www':
        source  => 'puppet:///modules/mailman/docroot/',
        owner   => 'root',
        group   => 'root',
        mode    => '0444',
        recurse => 'remote',
    }

    # Add a new default theme to make mailman prettier
    file { '/var/lib/mailman/templates':
        ensure => link,
        target => '/etc/mailman',
    }

    # Add default theme to make mailman prettier.
    #  Recurse => remote adds a bunch of files here and there
    #  while leaving the by-hand mailman config files in place.
    file { '/etc/mailman':
        source  => 'puppet:///modules/mailman/templates/',
        owner   => 'root',
        group   => 'root',
        mode    => '0444',
        recurse => 'remote',
    }

    # Not using require_package so apt::pin may be applied
    # before attempting to install package.
    package { 'libapache2-mod-security2':
        ensure => present,
    }

    # Ensure that the CRS modsecurity ruleset is not used. it has not
    # yet been tested for compatibility with our mailman instance and may
    # cause breakage.
    file { '/etc/apache2/mods-available/security2.conf':
        ensure  => present,
        source  => 'puppet:///modules/mailman/modsecurity/security2.conf',
        owner   => 'root',
        group   => 'root',
        mode    => '0644',
        require => Package['libapache2-mod-security2'],
    }

}