Convert all class usage to relative names

Change-Id: Ic7b8f4e584e3f1ed1d5c6c568cc6caf67493cdda
This commit is contained in:
Tobias Urdin 2019-12-08 23:24:12 +01:00
parent 298ab33801
commit a053d4e86e
23 changed files with 56 additions and 56 deletions

View File

@ -1,8 +1,8 @@
# This is an example of site.pp to deploy Trove
class { '::trove::client': }
class { 'trove::client': }
class { '::trove::keystone::auth':
class { 'trove::keystone::auth':
admin_address => '10.0.0.1',
internal_address => '10.0.0.1',
public_address => '10.0.0.1',
@ -10,28 +10,28 @@ class { '::trove::keystone::auth':
region => 'OpenStack'
}
class { '::trove::db::mysql':
class { 'trove::db::mysql':
password => 'dbpass',
host => '10.0.0.1',
allowed_hosts => ['10.0.0.1']
}
class { '::trove':
class { 'trove':
database_connection => 'mysql://trove:secrete@10.0.0.1/trove?charset=utf8',
default_transport_url => 'rabbit://trove:an_even_bigger_secret@10.0.0.1:5672/trove',
nova_proxy_admin_pass => 'novapass',
}
class { '::trove::api':
class { 'trove::api':
bind_host => '10.0.0.1',
auth_url => 'https://identity.openstack.org:5000/v3',
keystone_password => 'verysecrete'
}
class { '::trove::conductor':
class { 'trove::conductor':
auth_url => 'https://identity.openstack.org:5000/v3'
}
class { '::trove::taskmanager':
class { 'trove::taskmanager':
auth_url => 'https://identity.openstack.org:5000/v3'
}

View File

@ -115,10 +115,10 @@ class trove::api(
$taskmanager_queue = 'taskmanager',
) inherits trove {
include ::trove::deps
include ::trove::db
include ::trove::db::sync
include ::trove::params
include trove::deps
include trove::db
include trove::db::sync
include trove::params
# basic service config
trove_config {
@ -153,7 +153,7 @@ class trove::api(
}
if $auth_strategy == 'keystone' {
include ::trove::keystone::authtoken
include trove::keystone::authtoken
$trove_auth_url = "${regsubst($::trove::keystone::authtoken::www_authenticate_uri, '(\/v3$|\/v2.0$|\/$)', '')}/v3"
trove_config {

View File

@ -35,7 +35,7 @@ class trove::client (
$package_ensure = present,
) inherits trove::params {
include ::trove::deps
include trove::deps
package { 'python-troveclient':
ensure => $package_ensure,

View File

@ -74,8 +74,8 @@ class trove::conductor(
$trace_sqlalchemy = $::os_service_default,
) inherits trove {
include ::trove::deps
include ::trove::params
include trove::deps
include trove::params
if $::trove::database_connection {
if($::trove::database_connection =~ /mysql:\/\/\S+:\S+@\S+\/\S+/) {

View File

@ -69,7 +69,7 @@ class trove::config (
$trove_api_paste_ini = {},
) {
include ::trove::deps
include trove::deps
validate_legacy(Hash, 'validate_hash', $trove_config)
validate_legacy(Hash, 'validate_hash', $trove_taskmanager_config)

View File

@ -56,7 +56,7 @@ class trove::db (
$database_idle_timeout = undef,
) {
include ::trove::deps
include trove::deps
if $database_idle_timeout {
warning('The database_idle_timeout parameter is deprecated. Please use \

View File

@ -59,7 +59,7 @@ class trove::db::mysql(
$collate = 'utf8_general_ci',
) {
include ::trove::deps
include trove::deps
validate_legacy(String, 'validate_string', $password)

View File

@ -32,7 +32,7 @@ class trove::db::postgresql(
$privileges = 'ALL',
) {
include ::trove::deps
include trove::deps
validate_legacy(String, 'validate_string', $password)

View File

@ -19,7 +19,7 @@
#
class trove::db::sync {
include ::trove::deps
include trove::deps
exec { 'trove-manage db_sync':
path => '/usr/bin',

View File

@ -55,8 +55,8 @@ define trove::generic_service(
$package_ensure = 'present',
) {
include ::trove::deps
include ::trove::params
include trove::deps
include trove::params
$trove_title = "trove-${name}"

View File

@ -108,8 +108,8 @@ class trove::guestagent(
$control_exchange = undef,
) inherits trove {
include ::trove::deps
include ::trove::params
include trove::deps
include trove::params
if $control_exchange {
warning("control_exchange parameter is deprecated. Please use \

View File

@ -360,9 +360,9 @@ class trove(
$package_ensure = 'present',
) {
include ::trove::deps
include ::trove::policy
include ::trove::params
include trove::deps
include trove::policy
include trove::params
if $nova_compute_url {
trove_config { 'DEFAULT/nova_compute_url': value => $nova_compute_url }

View File

@ -104,7 +104,7 @@ class trove::keystone::auth (
$internal_url = 'http://127.0.0.1:8779/v1.0/%(tenant_id)s',
) {
include ::trove::deps
include trove::deps
Keystone_user_role["${auth_name}@${tenant}"] ~> Service <| tag == 'trove-service' |>

View File

@ -208,7 +208,7 @@ class trove::keystone::authtoken(
$service_token_roles_required = $::os_service_default,
) {
include ::trove::deps
include trove::deps
if is_service_default($password) {
fail('Please set password for trove service user')

View File

@ -120,7 +120,7 @@ class trove::logging(
$log_date_format = $::os_service_default,
) {
include ::trove::deps
include trove::deps
oslo::log { 'trove_config':
debug => $debug,

View File

@ -3,7 +3,7 @@
# Parameters for puppet-trove
#
class trove::params {
include ::openstacklib::defaults
include openstacklib::defaults
$pyvers = $::openstacklib::defaults::pyvers
$client_package_name = "python${pyvers}-troveclient"

View File

@ -28,8 +28,8 @@ class trove::policy (
$policy_path = '/etc/trove/policy.json',
) {
include ::trove::deps
include ::trove::params
include trove::deps
include trove::params
validate_legacy(Hash, 'validate_hash', $policies)

View File

@ -52,7 +52,7 @@ class trove::quota (
$max_backups_per_user = undef,
) {
include ::trove::deps
include trove::deps
if $max_instances_per_user {
warning("max_instances_per_user deprecated, has no effect and will be removed after Newton cycle. \

View File

@ -105,8 +105,8 @@ class trove::taskmanager(
$use_guestagent_template = true,
) inherits trove {
include ::trove::deps
include ::trove::params
include trove::deps
include trove::params
if $default_neutron_networks {
warning("trove::taskmanager::default_neutron_networks is deprecated and will be removed in \

View File

@ -6,12 +6,12 @@ describe 'basic trove' do
it 'should work with no errors' do
pp= <<-EOS
include ::openstack_integration
include ::openstack_integration::repos
include ::openstack_integration::rabbitmq
include ::openstack_integration::mysql
include ::openstack_integration::keystone
include ::openstack_integration::trove
include openstack_integration
include openstack_integration::repos
include openstack_integration::rabbitmq
include openstack_integration::mysql
include openstack_integration::keystone
include openstack_integration::trove
EOS

View File

@ -45,7 +45,7 @@ describe 'trove::api' do
glance_endpoint_type => '<SERVICE DEFAULT>',
neutron_endpoint_type => '<SERVICE DEFAULT>',
}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -154,7 +154,7 @@ describe 'trove::api' do
"class { 'trove':
nova_proxy_admin_pass => 'verysecrete',
single_tenant_mode => 'true'}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -170,7 +170,7 @@ describe 'trove::api' do
"class { 'trove':
nova_proxy_admin_pass => 'verysecrete',
}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -187,7 +187,7 @@ describe 'trove::api' do
rabbit_ha_queues => 'true',
amqp_durable_queues => 'true',
}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -203,7 +203,7 @@ describe 'trove::api' do
nova_proxy_admin_pass => 'verysecrete',
rabbit_ha_queues => 'true',
}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -219,7 +219,7 @@ describe 'trove::api' do
use_neutron => true,
default_neutron_networks => 'trove_service',
}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -240,7 +240,7 @@ describe 'trove::api' do
nova_proxy_admin_pass => 'verysecrete',
use_neutron => false
}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -266,7 +266,7 @@ describe 'trove::api' do
kombu_ssl_certfile => '/path/to/ssl/cert/file',
kombu_ssl_keyfile => '/path/to/ssl/keyfile',
kombu_ssl_version => 'TLSv1'}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -287,7 +287,7 @@ describe 'trove::api' do
"class { 'trove':
nova_proxy_admin_pass => 'verysecrete',
rabbit_use_ssl => true}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -308,7 +308,7 @@ describe 'trove::api' do
"class { 'trove':
nova_proxy_admin_pass => 'verysecrete',
rabbit_use_ssl => false}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -332,7 +332,7 @@ describe 'trove::api' do
rpc_response_timeout => '120',
control_exchange => 'openstack',
notification_transport_url => 'rabbit://rabbit_user:password@localhost:5673' }
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end
@ -350,7 +350,7 @@ describe 'trove::api' do
"class { 'trove' :
nova_proxy_admin_pass => 'verysecrete',
}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end

View File

@ -62,7 +62,7 @@ describe 'trove::conductor' do
"class { 'trove':
nova_proxy_admin_pass => 'verysecrete',
single_tenant_mode => 'true'}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end

View File

@ -123,7 +123,7 @@ describe 'trove::taskmanager' do
"class { 'trove':
nova_proxy_admin_pass => 'verysecrete',
single_tenant_mode => 'true'}
class { '::trove::keystone::authtoken':
class { 'trove::keystone::authtoken':
password => 'a_big_secret',
}"
end