system-config/modules/openstack_project/manifests/zuul_merger.pp
James E. Blair deed969d2d Update review.o.o ip addresses
Which are used in the puppet-managed known_hosts files for zuul.

Change-Id: I2664f609f6172515f2933b06cb06eb6a5d3ca9a7
2014-04-28 14:28:13 -07:00

56 lines
1.5 KiB
Puppet

# == Class: openstack_project::zuul_merger
#
class openstack_project::zuul_merger(
$vhost_name = $::fqdn,
$gearman_server = '127.0.0.1',
$gerrit_server = '',
$gerrit_user = '',
$gerrit_ssh_host_key = '',
$zuul_ssh_private_key = '',
$zuul_url = "http://${::fqdn}/p",
$sysadmins = [],
) {
class { 'openstack_project::server':
iptables_public_tcp_ports => [80],
sysadmins => $sysadmins,
}
class { '::zuul':
vhost_name => $vhost_name,
gearman_server => $gearman_server,
gerrit_server => $gerrit_server,
gerrit_user => $gerrit_user,
zuul_ssh_private_key => $zuul_ssh_private_key,
zuul_url => $zuul_url,
git_email => 'jenkins@openstack.org',
git_name => 'OpenStack Jenkins',
}
class { '::zuul::merger': }
if $gerrit_ssh_host_key != '' {
file { '/home/zuul/.ssh':
ensure => directory,
owner => 'zuul',
group => 'zuul',
mode => '0700',
require => Class['::zuul'],
}
file { '/home/zuul/.ssh/known_hosts':
ensure => present,
owner => 'zuul',
group => 'zuul',
mode => '0600',
content => "review.openstack.org,23.253.232.87,2001:4800:7815:104:3bc3:d7f6:ff03:bf5d ${gerrit_ssh_host_key}",
replace => true,
require => File['/home/zuul/.ssh'],
}
}
file { '/etc/zuul/merger-logging.conf':
ensure => present,
source => 'puppet:///modules/openstack_project/zuul/merger-logging.conf',
}
}