Puppetizing mailing lists

Allow for mailing lists to be created with a request for review.

Change-Id: I8b3b0965119418cfc9286cd20221fe38ffd06b24
Reviewed-on: https://review.openstack.org/29833
Reviewed-by: Clark Boylan <clark.boylan@gmail.com>
Reviewed-by: Jeremy Stanley <fungi@yuggoth.org>
Reviewed-by: Elizabeth Krumbach Joseph <lyz@princessleia.com>
Approved: James E. Blair <corvus@inaugust.com>
Reviewed-by: James E. Blair <corvus@inaugust.com>
Tested-by: Jenkins
This commit is contained in:
Stefano Maffulli 2013-05-20 13:47:24 -07:00 committed by Jenkins
parent da3cbb4f21
commit b8e8e502cf
2 changed files with 20 additions and 4 deletions

View File

@ -123,7 +123,8 @@ node 'groups.openstack.org' {
node 'lists.openstack.org' {
class { 'openstack_project::lists':
listadmins => hiera('listadmins'),
listadmins => hiera('listadmins'),
listpassword => hiera('listpassword'),
}
}

View File

@ -1,6 +1,9 @@
# == Class: openstack_project::lists
#
class openstack_project::lists($listadmins = '') {
class openstack_project::lists(
$listadmins,
$listpassword = ''
) {
# Using openstack_project::template instead of openstack_project::server
# because the exim config on this machine is almost certainly
# going to be more complicated than normal.
@ -8,17 +11,29 @@ class openstack_project::lists($listadmins = '') {
iptables_public_tcp_ports => [25, 80, 465],
}
$listdomain = 'lists.openstack.org'
class { 'exim':
sysadmin => $listadmins,
mailman_domains => ['lists.openstack.org'],
mailman_domains => [$listdomain],
}
class { 'mailman':
vhost_name => 'lists.openstack.org',
vhost_name => $listdomain,
}
realize (
User::Virtual::Localuser['oubiwann'],
User::Virtual::Localuser['smaffulli'],
)
maillist { 'openstack-it':
ensure => present,
admin => 'stefano@openstack.org',
password => $listpassword,
description => 'Discussioni su OpenStack in italiano',
webserver => $listdomain,
mailserver => $listdomain,
}
}