Convert all class usage to relative names

Change-Id: Ia6a3c71dbca4659ff9375ae813f990b162e57c02
This commit is contained in:
Tobias Urdin 2019-12-08 23:10:29 +01:00
parent e530c8bc71
commit 38c4e3104a
38 changed files with 78 additions and 78 deletions

View File

@ -99,9 +99,9 @@ class manila::api (
$os_region_name = undef,
) inherits manila::params {
include ::manila::deps
include ::manila::params
include ::manila::policy
include manila::deps
include manila::params
include manila::policy
require ::keystone::client
if $service_port {
@ -121,7 +121,7 @@ class manila::api (
}
if $sync_db {
include ::manila::db::sync
include manila::db::sync
}
if $enabled {
@ -146,7 +146,7 @@ class manila::api (
} elsif $service_name == 'httpd' {
# We need to make sure manila-api/eventlet is stopped before trying to
# start apache
include ::apache::params
include apache::params
service { 'manila-api':
ensure => 'stopped',
name => $::manila::params::api_service,
@ -177,7 +177,7 @@ server.")
manila_config {
'DEFAULT/auth_strategy': value => $auth_strategy;
}
include ::manila::keystone::authtoken
include manila::keystone::authtoken
if ($ratelimits != undef) {
manila_api_paste_ini {

View File

@ -83,7 +83,7 @@ define manila::backend::cephfs (
$cephfs_protocol_helper_type = 'CEPHFS',
) {
include ::manila::deps
include manila::deps
$share_driver = 'manila.share.drivers.cephfs.driver.CephFSDriver'

View File

@ -67,7 +67,7 @@ define manila::backend::dellemc_isilon (
$package_ensure = 'present',
) {
include ::manila::deps
include manila::deps
validate_legacy(String, 'validate_string', $emc_nas_password)

View File

@ -92,7 +92,7 @@ define manila::backend::dellemc_unity (
$package_ensure = 'present',
) {
include ::manila::deps
include manila::deps
validate_legacy(String, 'validate_string', $emc_nas_password)

View File

@ -71,7 +71,7 @@ define manila::backend::dellemc_vmax (
$package_ensure = 'present',
) {
include ::manila::deps
include manila::deps
validate_legacy(String, 'validate_string', $emc_nas_password)

View File

@ -91,7 +91,7 @@ define manila::backend::dellemc_vnx (
$package_ensure = 'present',
) {
include ::manila::deps
include manila::deps
validate_legacy(String, 'validate_string', $emc_nas_password)

View File

@ -88,7 +88,7 @@ define manila::backend::generic (
$automatic_share_server_cleanup = 'True',
) {
include ::manila::deps
include manila::deps
$share_driver = 'manila.share.drivers.generic.GenericShareDriver'

View File

@ -28,7 +28,7 @@ define manila::backend::glusterfs (
$glusterfs_mount_point_base = '$state_path/mnt',
) {
include ::manila::deps
include manila::deps
$share_driver = 'manila.share.drivers.glusterfs.GlusterfsShareDriver'
manila_config {

View File

@ -31,8 +31,8 @@ define manila::backend::glusternative (
$package_ensure = 'present',
) {
include ::manila::deps
include ::manila::params
include manila::deps
include manila::params
$share_driver = 'manila.share.drivers.glusterfs_native.GlusterfsNativeShareDriver'

View File

@ -42,8 +42,8 @@ define manila::backend::glusternfs (
$package_ensure = 'present',
) {
include ::manila::deps
include ::manila::params
include manila::deps
include manila::params
$share_driver = 'manila.share.drivers.glusterfs.GlusterfsShareDriver'

View File

@ -61,7 +61,7 @@ define manila::backend::hitachi_hnas (
$package_ensure = 'present',
) {
include ::manila::deps
include manila::deps
validate_legacy(String, 'validate_string', $hitachi_hnas_password)

View File

@ -120,7 +120,7 @@ define manila::backend::netapp (
$package_ensure = 'present',
) {
include ::manila::deps
include manila::deps
validate_legacy(String, 'validate_string', $netapp_password)

View File

@ -14,7 +14,7 @@ class manila::backends (
$enabled_share_backends = undef
) {
include ::manila::deps
include manila::deps
# Maybe this could be extended to dynamically find the enabled names
manila_config {

View File

@ -11,8 +11,8 @@ class manila::client (
$package_ensure = 'present'
) {
include ::manila::deps
include ::manila::params
include manila::deps
include manila::params
package { 'python-manilaclient':
ensure => $package_ensure,

View File

@ -111,7 +111,7 @@ class manila::compute::nova (
$nova_admin_auth_url = undef,
) {
include ::manila::deps
include manila::deps
if $nova_catalog_info {
warning('The nova_catalog_info parameter is deprecated, has no effect and will be removed in a future release.')

View File

@ -32,7 +32,7 @@ class manila::config (
$api_paste_ini_config = {},
) {
include ::manila::deps
include manila::deps
validate_legacy(Hash, 'validate_hash', $manila_config)
validate_legacy(Hash, 'validate_hash', $api_paste_ini_config)

View File

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

View File

@ -45,7 +45,7 @@ class manila::db::mysql (
$cluster_id = 'localzone',
) {
include ::manila::deps
include manila::deps
validate_legacy(String, 'validate_string', $password)

View File

@ -32,7 +32,7 @@ class manila::db::postgresql(
$privileges = 'ALL',
) {
include ::manila::deps
include manila::deps
::openstacklib::db::postgresql { 'manila':
password_hash => postgresql_password($user, $password),

View File

@ -1,8 +1,8 @@
#
class manila::db::sync {
include ::manila::params
include ::manila::deps
include manila::params
include manila::deps
exec { 'manila-manage db_sync':
command => $::manila::params::db_sync_command,

View File

@ -39,7 +39,7 @@ class manila::ganesha (
$ganesha_export_template_dir = '/etc/manila/ganesha-export-templ.d',
) {
include ::manila::deps
include manila::deps
manila_config {
'DEFAULT/ganesha_config_dir': value => $ganesha_config_dir;

View File

@ -273,9 +273,9 @@ class manila (
$host = $::os_service_default,
) {
include ::manila::deps
include ::manila::db
include ::manila::params
include manila::deps
include manila::db
include manila::params
if $use_ssl {
if !$cert_file {

View File

@ -131,7 +131,7 @@ class manila::keystone::auth (
$internal_url_v2 = 'http://127.0.0.1:8786/v2/%(tenant_id)s',
) {
include ::manila::deps
include manila::deps
# for interface backward compatibility, we can't enforce to set a new parameter
# so we take 'password' parameter by default but allow to override it.

View File

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

View File

@ -119,7 +119,7 @@ class manila::logging(
$log_date_format = $::os_service_default,
) {
include ::manila::deps
include manila::deps
oslo::log { 'manila_config':
debug => $debug,

View File

@ -4,7 +4,7 @@
#
class manila::params {
include ::openstacklib::defaults
include openstacklib::defaults
$pyvers = $::openstacklib::defaults::pyvers
$client_package = "python${pyvers}-manilaclient"

View File

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

View File

@ -50,7 +50,7 @@ class manila::quota (
$max_age = 0,
) {
include ::manila::deps
include manila::deps
manila_config {
'DEFAULT/quota_shares': value => $quota_shares;

View File

@ -37,7 +37,7 @@ class manila::rabbitmq(
$port = '5672',
) {
include ::manila::deps
include manila::deps
warning('manila::rabbitmq class is deprecated and will be removed in next release. Make other plans to configure rabbitmq resources.')

View File

@ -27,8 +27,8 @@ class manila::scheduler (
$manage_service = true
) {
include ::manila::deps
include ::manila::params
include manila::deps
include manila::params
Manila_config<||> ~> Service['manila-scheduler']
Manila_api_paste_ini<||> ~> Service['manila-scheduler']

View File

@ -104,7 +104,7 @@ define manila::service_instance (
) {
include ::manila::deps
include manila::deps
if $service_instance_network_helper_type {
warning('service_instance_network_helper_type is deprecated, has no effect, and will be removed in the future.')

View File

@ -21,8 +21,8 @@ class manila::share (
$manage_service = true
) {
include ::manila::deps
include ::manila::params
include manila::deps
include manila::params
Manila_config<||> ~> Service['manila-share']
Manila_api_paste_ini<||> ~> Service['manila-share']

View File

@ -45,8 +45,8 @@ define manila::type (
$volume_name = $name
include ::manila::deps
include ::manila::client
include manila::deps
include manila::client
# TODO: (xarses) This should be moved to a ruby provider so that among other
# reasons, the credential discovery magic can occur like in neutron.

View File

@ -38,8 +38,8 @@ define manila::type_set (
$os_region_name = undef,
) {
include ::manila::deps
include ::manila::client
include manila::deps
include manila::client
# TODO: (xarses) This should be moved to a ruby provider so that among other
# reasons, the credential discovery magic can occur like in neutron.

View File

@ -56,7 +56,7 @@ class manila::volume::cinder (
$cinder_admin_auth_url = 'http://localhost:5000/v3',
) {
include ::manila::deps
include manila::deps
manila_config {
'DEFAULT/cinder_catalog_info': value => $cinder_catalog_info;

View File

@ -123,12 +123,12 @@ class manila::wsgi::apache (
$custom_wsgi_process_options = {},
) {
include ::manila::deps
include ::manila::params
include ::apache
include ::apache::mod::wsgi
include manila::deps
include manila::params
include apache
include apache::mod::wsgi
if $ssl {
include ::apache::mod::ssl
include apache::mod::ssl
}
::openstacklib::wsgi::apache { 'manila_wsgi':

View File

@ -6,11 +6,11 @@ describe 'basic manila' 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
include openstack_integration::repos
include openstack_integration::rabbitmq
include openstack_integration::mysql
include openstack_integration::keystone
rabbitmq_user { 'manila':
admin => true,
@ -28,35 +28,35 @@ describe 'basic manila' do
}
# Manila resources
class { '::manila::logging':
class { 'manila::logging':
debug => true,
}
class { '::manila':
class { 'manila':
default_transport_url => 'rabbit://manila:an_even_bigger_secret@127.0.0.1:5672/',
sql_connection => 'mysql+pymysql://manila:a_big_secret@127.0.0.1/manila?charset=utf8',
}
class { '::manila::db::mysql':
class { 'manila::db::mysql':
password => 'a_big_secret',
}
class { '::manila::keystone::auth':
class { 'manila::keystone::auth':
password => 'a_big_secret',
password_v2 => 'a_big_secret',
}
class { '::manila::client': }
class { '::manila::compute::nova': }
class { '::manila::network::neutron': }
class { '::manila::volume::cinder': }
class { '::manila::keystone::authtoken':
class { 'manila::client': }
class { 'manila::compute::nova': }
class { 'manila::network::neutron': }
class { 'manila::volume::cinder': }
class { 'manila::keystone::authtoken':
password => 'a_big_secret',
}
class { '::manila::api':
class { 'manila::api':
service_name => 'httpd',
}
include ::apache
class { '::manila::wsgi::apache':
include apache
class { 'manila::wsgi::apache':
ssl => false,
}
class { '::manila::scheduler': }
class { 'manila::scheduler': }
# missing: backends, share, service_instance
EOS

View File

@ -153,9 +153,9 @@ describe 'manila::api' do
end
let :pre_condition do
"include ::apache
"include apache
class { 'manila': }
class { '::manila::keystone::authtoken':
class { 'manila::keystone::authtoken':
password => 'foo',
}"
end
@ -175,9 +175,9 @@ describe 'manila::api' do
end
let :pre_condition do
"include ::apache
"include apache
class { 'manila': }
class { '::manila::keystone::authtoken':
class { 'manila::keystone::authtoken':
password => 'foo',
}"
end