Puppet Class: mw_rc_irc::ircserver

Defined in:
modules/mw_rc_irc/manifests/ircserver.pp

Overview

Sets up the Wikimedia (read-only) IRCd This is a modified ircd server and is not suitable for a general ircd deployment



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
# File 'modules/mw_rc_irc/manifests/ircserver.pp', line 4

class mw_rc_irc::ircserver {

    require_package('ircd-ratbox', 'irssi')

    # public part of the ircd config
    file { '/usr/etc/ircd.conf':
        mode    => '0444',
        owner   => 'irc',
        group   => 'irc',
        content => template('mw_rc_irc/ircd.conf.erb');
    }

    # private config block for auth/allowed users
    file { '/usr/etc/auth.conf':
        mode      => '0444',
        owner     => 'irc',
        group     => 'irc',
        content   => secret('mw_rc_irc/auth.conf'),
        show_diff => false,
    }

    # private config block for operators and their passwords
    file { '/usr/etc/operator.conf':
        mode      => '0444',
        owner     => 'irc',
        group     => 'irc',
        content   => secret('mw_rc_irc/operator.conf'),
        show_diff => false,
    }

    # message of the day / connect banner
    file { '/usr/etc/ircd.motd':
        mode    => '0444',
        owner   => 'irc',
        group   => 'irc',
        content => template('mw_rc_irc/motd.erb');
    }

    file { '/etc/systemd/system/ircd.service':
        owner  => 'root',
        group  => 'root',
        mode   => '0444',
        source => 'puppet:///modules/mw_rc_irc/systemd/ircd.service',
    }

    service { 'ircd':
        ensure   => running,
        provider => 'systemd',
        require  => File['/etc/systemd/system/ircd.service'],
    }

    monitoring::service { 'ircd':
        description   => 'ircd',
        check_command => 'check_ircd',
        critical      => true,
        notes_url     => 'https://wikitech.wikimedia.org/wiki/Irc.wikimedia.org',
    }
}