Add email servers to firehose

A requirement for running lpmqtt is to have an imap server that is
subscribed to launchpad notifications to use as a source for the event
stream. However there is no preexisting imap server setup anywhere to
use for this. This commit deploys the necessary components for the imap
server. Setting up the launchpad user and the subscription will be a
manual process.

Change-Id: I063ac9da89d227ac59ca1cb8765e3615d7bfdbba
This commit is contained in:
Matthew Treinish 2016-09-13 16:15:56 -04:00
parent 205c687115
commit 7c45912e9f
No known key found for this signature in database
GPG Key ID: FD12A0F214C9E177
2 changed files with 30 additions and 1 deletions

View File

@ -492,10 +492,12 @@ node /^elasticsearch0[1-7]\.openstack\.org$/ {
# Node-OS: xenial
node /^firehose\d+\.openstack\.org$/ {
class { 'openstack_project::server':
iptables_public_tcp_ports => [22, 80, 1883, 8080, 8883],
iptables_public_tcp_ports => [22, 25, 80, 143, 993, 1883, 8080, 8883],
sysadmins => hiera('sysadmins', []),
manage_exim => false,
}
class { 'openstack_project::firehose':
sysadmins => hiera('sysadmins', []),
gerrit_ssh_host_key => hiera('gerrit_ssh_rsa_pubkey_contents'),
gerrit_public_key => hiera('germqtt_gerrit_ssh_public_key'),
gerrit_private_key => hiera('germqtt_gerrit_ssh_private_key'),

View File

@ -15,6 +15,7 @@
# firehose glue class.
#
class openstack_project::firehose (
$sysadmins = [],
$gerrit_username = 'germqtt',
$gerrit_public_key,
$gerrit_private_key,
@ -45,4 +46,30 @@ class openstack_project::firehose (
mqtt_username => $mqtt_username,
mqtt_password => $mqtt_password,
}
package {'cyrus-imapd':
ensure => latest,
}
class {'::exim':
sysadmins => $sysadmins,
routers => [
{'cyrus' => {
'driver' => 'accept',
'domains' => '+local_domains',
'local_part_suffix' => '+*',
'local_part_suffix_optional' => true,
'transport' => 'cyrus',
}}
],
transports => [
{'cyrus' => {
'driver' => 'lmtp',
'socket' => '/var/run/cyrus/socket/lmtp',
'user' => 'cyrus',
'batch_max' => '35',
}}
],
require => Package['cyrus-imapd'],
}
}