puppet-zuul/spec/acceptance/fixtures/preconditions.pp
Ian Wienand a1d11f90fe Replace openstack.org git:// URLs with https://
This is a mechanically generated change to replace openstack.org
git:// URLs with https:// equivalents.

This is in aid of a planned future move of the git hosting
infrastructure to a self-hosted instance of gitea (https://gitea.io),
which does not support the git wire protocol at this stage.

This update should result in no functional change.

For more information see the thread at

 http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003825.html

Change-Id: Ic33f4903f6ca065b733960e3c476f591d5774044
2019-03-24 20:35:47 +00:00

35 lines
768 B
Puppet

# Installing ssl-cert in order to get snakeoil certs
package { 'ssl-cert':
ensure => present,
}
vcsrepo { '/etc/project-config':
ensure => latest,
provider => git,
revision => 'master',
source => 'https://git.openstack.org/openstack-infra/project-config',
}
# Creating ssh rsa keys
define ssh_keygen (
$ssh_directory = undef
) {
Exec { path => '/bin:/usr/bin' }
$ssh_key_file = "${ssh_directory}/${name}"
exec { "ssh-keygen for ${name}":
command => "ssh-keygen -t rsa -f ${ssh_key_file} -N ''",
creates => $ssh_key_file,
}
}
$ssh_key_directory = '/tmp/zuul-ssh-keys'
file { $ssh_key_directory:
ensure => directory
}
ssh_keygen {'ssh_rsa_key':
ssh_directory => $ssh_key_directory,
require => File[$ssh_key_directory],
}