Merge pull request #188 from michaeltchapman/tempest_testing

Add optional tempest suite to controller
This commit is contained in:
Dan Bode
2013-10-31 15:52:20 -07:00
11 changed files with 50 additions and 7 deletions

View File

@@ -17,3 +17,5 @@ network_type: per-tenant-router
# supports gre or vlan
tenant_network_type: gre
enable_ha: false
install_tempest: false

View File

@@ -51,3 +51,11 @@ apache::mpm_module: prefork
# Fix odd behaviors
horizon::django_debug: true
# Tempest configuration
openstack::provision::identity_uri: 'http://127.0.0.1:5000/v2.0/'
openstack::provision::admin_tenant_name: openstack
openstack::provision::admin_password: Cisco123
openstack::provision::resize_available: false
openstack::provision::change_password_available: false
openstack::provision::public_network_name: nova

View File

@@ -36,6 +36,7 @@ nodes:
- 'pw-mirror-network'
- 'apt-packages'
- 'cloud-init-log'
- 'git-proxy'
- 'puppet-modules'
- 'hiera-config'
- 'puppet-master-fact'
@@ -63,7 +64,9 @@ nodes:
- 'pw-mirror-network'
- 'apt-packages'
- 'cloud-init-log'
- 'puppet-modules-lite'
- 'git-proxy'
- 'puppet-modules'
- 'puppet-agent-fact'
- 'hiera-config'
- 'puppet-setup'
- 'WAIT_stack build-server'
@@ -85,7 +88,9 @@ nodes:
- 'pw-mirror-network'
- 'apt-packages'
- 'cloud-init-log'
- 'puppet-modules-lite'
- 'git-proxy'
- 'puppet-modules'
- 'puppet-agent-fact'
- 'hiera-config'
- 'puppet-setup'
- 'WAIT_stack build-server'

View File

@@ -0,0 +1,6 @@
roles:
controller:
classes:
- openstack::provision

View File

@@ -24,7 +24,6 @@ case $::osfamily {
$pkg_list = ['git', 'curl', 'vim', 'cobbler']
package { 'puppet-common':
ensure => $puppet_version,
require => Apt::Source[puppetlabs]
}
}
}
@@ -41,6 +40,14 @@ if $::build_server_ip {
}
}
if $::apt_proxy_host {
class { 'apt':
proxy_host => $::apt_proxy_host,
proxy_port => $::apt_proxy_port
}
}
#
# configure data or all machines who
# have run mode set to master or apply
@@ -75,6 +82,7 @@ if $::puppet_run_mode != 'agent' {
- user.common
- "osfamily/%{osfamily}"
- "enable_ha/%{enable_ha}"
- "install_tempest/%{install_tempest}"
- "cinder_backend/%{cinder_backend}"
- "glance_backend/%{glance_backend}"
- "rpc_type/%{rpc_type}"

View File

@@ -339,7 +339,11 @@ def cli_get(n,q,k,args):
for test_id, servers in run_instances.items():
print "Test ID: " + test_id
for server in servers:
print "%-8.8s %16.16s %12.12s" % (server.id, server.name, str(server.networks['ci'][0]))
if 'ci' in server.networks:
print "%-16.16s %16.16s %12.12s" % (str(server.networks['ci'][0]), server.name, server.id)
else:
print "%-16.16s %16.16s %12.12s" % ('-', server.name, server.id)
def get(n, q, k, args):
run_instances = {}

View File

@@ -1,2 +1,2 @@
apt-get update
apt-get install -y puppet git rubygems curl python-yaml apache2
apt-get install -y puppet git rubygems curl python-yaml apache2 socat

View File

@@ -0,0 +1,7 @@
echo '#!/bin/bash' > /usr/bin/gitproxy
echo '_proxy=%{apt_proxy_host}' >> /usr/bin/gitproxy
echo '_proxyport=%{apt_proxy_port}' >> /usr/bin/gitproxy
echo 'exec socat STDIO PROXY:$_proxy:$1:$2,proxyport=$_proxyport' >> /usr/bin/gitproxy
chmod a+x /usr/bin/gitproxy
git config --system core.gitproxy gitproxy

View File

@@ -0,0 +1,3 @@
# By default, setup.pp will omit some components
# required by puppet master
export FACTER_puppet_run_mode=agent

View File

@@ -6,7 +6,7 @@ export GEM_HOME=`pwd`/vendor
gem install thor --no-ri --no-rdoc
git clone https://github.com/bodepd/librarian-puppet-simple.git vendor/librarian-puppet-simple
export PATH=`pwd`/vendor/librarian-puppet-simple/bin/:$PATH
export git_protocol='https'
export git_protocol=%{git_protocol}
export openstack_version=%{openstack_version}
librarian-puppet install --verbose --path /etc/puppet/modules

View File

@@ -1,2 +1,2 @@
# Install the latest puppet and purge the old puppet
puppet apply manifests/setup.pp
puppet apply manifests/setup.pp --certname setup_cert