Add reprepro to release slave

The Packaging-deb team will be starting to publish packages to AFS.
This patch is the first step to allow that.

Change-Id: I9d8d5ce384a371042928587c0debf0da37352ad8
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
This commit is contained in:
Paul Belanger 2016-07-04 11:55:59 -04:00
parent 9d764f1631
commit bec8458406
No known key found for this signature in database
GPG Key ID: 611A80832067AF38
3 changed files with 33 additions and 7 deletions

View File

@ -32,6 +32,7 @@ class openstack_project::release_slave (
$npm_userpassword, $npm_userpassword,
$npm_userurl, $npm_userurl,
$admin_keytab = '', $admin_keytab = '',
$packaging_keytab = '',
) { ) {
class { 'openstack_project::slave': class { 'openstack_project::slave':
ssh_key => $jenkins_ssh_public_key, ssh_key => $jenkins_ssh_public_key,
@ -105,4 +106,20 @@ class openstack_project::release_slave (
require => File['/home/jenkins'], require => File['/home/jenkins'],
} }
include ::openstack_project::reprepro_mirror
file { '/etc/packaging.keytab':
owner => 'root',
group => 'root',
mode => '0400',
content => $packaging_keytab,
}
### Debian Openstack Packages ###
::openstack_project::reprepro { 'debian-openstack-reprepro':
confdir => '/etc/reprepro/debian-openstack',
basedir => '/afs/.openstack.org/mirror/debian-openstack',
distributions => 'openstack_project/reprepro/distributions.debian-openstack.erb',
releases => ['jessie'],
}
} }

View File

@ -5,7 +5,7 @@ define openstack_project::reprepro (
$basedir, $basedir,
$distributions, $distributions,
$logdir = '/var/log/reprepro', $logdir = '/var/log/reprepro',
$updates_file, $updates_file = undef,
$options_template = 'openstack_project/reprepro/options.erb', $options_template = 'openstack_project/reprepro/options.erb',
$releases = [], $releases = [],
) { ) {
@ -13,6 +13,7 @@ define openstack_project::reprepro (
ensure => directory, ensure => directory,
} }
if $updates_file != undef {
file { "${confdir}/updates": file { "${confdir}/updates":
ensure => present, ensure => present,
owner => 'root', owner => 'root',
@ -20,6 +21,7 @@ define openstack_project::reprepro (
mode => '0755', mode => '0755',
source => $updates_file, source => $updates_file,
} }
}
file { "${confdir}/options": file { "${confdir}/options":
ensure => present, ensure => present,

View File

@ -0,0 +1,7 @@
<% @releases.each do |release| -%>
Codename: <%= release %>
Description: Debian OpenStack <%= release.capitalize %> packages
Architectures: amd64 i386 source
Components: main
<% end -%>