From 23811d6122113af029d08a296ddaaa5f9684e249 Mon Sep 17 00:00:00 2001 From: Paul Belanger Date: Sun, 22 Sep 2013 23:34:33 -0400 Subject: [PATCH] Expose debug parameter Simple patch to expose the debug parameter, just like we do with verbose. Change-Id: I70122f57f524af7deaa502eafa4fb482af076753 Signed-off-by: Paul Belanger --- manifests/all.pp | 7 +++++++ spec/classes/openstack_all_spec.rb | 6 ++++++ 2 files changed, 13 insertions(+) diff --git a/manifests/all.pp b/manifests/all.pp index 2121e6f..1a5fa65 100644 --- a/manifests/all.pp +++ b/manifests/all.pp @@ -30,6 +30,7 @@ # [fixed_range] Range of ipv4 network for vms. # [floating_range] Floating ip range to create. # [create_networks] Rather network and floating ips should be created. +# [debug] (bool) Whether to log services at debug. Default to: false. # [num_networks] Number of networks that fixed range should be split into. # [multi_host] Rather node should support multi-host networking mode for HA. # Optional. Defaults to false. @@ -220,6 +221,7 @@ class openstack::all ( $bridge_uplinks = undef, $tenant_network_type = 'gre', # General + $debug = false, $verbose = false, $enabled = true ) { @@ -304,6 +306,7 @@ class openstack::all ( db_password => $keystone_db_password, db_name => $keystone_db_dbname, db_user => $keystone_db_user, + debug => $debug, admin_token => $keystone_admin_token, admin_tenant => $keystone_admin_tenant, admin_email => $admin_email, @@ -328,6 +331,7 @@ class openstack::all ( verbose => $verbose, db_type => $db_type, db_host => $db_host, + debug => $debug, keystone_host => $keystone_host, db_user => $glance_db_user, db_name => $glance_db_dbname, @@ -406,6 +410,7 @@ class openstack::all ( vnc_enabled => $vnc_enabled, vncproxy_host => $vncproxy_host_real, # General + debug => $debug, verbose => $verbose, enabled => $enabled, } @@ -438,6 +443,7 @@ class openstack::all ( } class { 'openstack::neutron': + debug => $debug, # Database db_host => $db_host, # Rabbit @@ -505,6 +511,7 @@ class openstack::all ( class { 'openstack::cinder::all': bind_host => $cinder_bind_address, + debug => $debug, keystone_auth_host => $keystone_host, keystone_password => $cinder_user_password, rabbit_userid => $rabbit_user, diff --git a/spec/classes/openstack_all_spec.rb b/spec/classes/openstack_all_spec.rb index 98d556e..583e947 100644 --- a/spec/classes/openstack_all_spec.rb +++ b/spec/classes/openstack_all_spec.rb @@ -121,6 +121,7 @@ describe 'openstack::all' do :keystone_host => '127.0.0.1', :enabled => true, :enable_server => true, + :debug => false, :verbose => false ) end @@ -166,6 +167,7 @@ describe 'openstack::all' do :keystone_host => '127.0.0.1', :enabled => true, :enable_server => true, + :debug => false, :verbose => false ) end @@ -218,6 +220,7 @@ describe 'openstack::all' do :setup_test_volume => false, :manage_volumes => true, :volume_group => 'cinder-volumes', + :debug => false, :verbose => false ) should contain_nova_config('DEFAULT/volume_api_class').with(:value => 'nova.volume.cinder.API') @@ -291,6 +294,7 @@ describe 'openstack::all' do it 'should have openstack::keystone configured' do should contain_class('openstack::keystone').with( + :debug => false, :verbose => false, :db_type => 'mysql', :db_host => '127.0.0.1', @@ -318,6 +322,7 @@ describe 'openstack::all' do it 'should have openstack::glance configured' do should contain_class('openstack::glance').with( + :debug => false, :verbose => false, :db_type => 'mysql', :db_host => '127.0.0.1', @@ -380,6 +385,7 @@ describe 'openstack::all' do :glance_api_servers => '10.0.0.1:9292', :vnc_enabled => true, :vncproxy_host => '10.0.0.1', + :debug => false, :verbose => false, :enabled => true )