Browse Source

Convert all class usage to relative names

Change-Id: I9ff8d888e367a46ab89e3668bf4ba76c4c7c127c
changes/00/697900/1
Tobias Urdin 2 years ago
parent
commit
ed9298e996
39 changed files with 63 additions and 63 deletions
  1. +3
    -3
      examples/glance_multi_store.pp
  2. +2
    -2
      examples/glance_single_store.pp
  3. +6
    -6
      manifests/api.pp
  4. +1
    -1
      manifests/api/authtoken.pp
  5. +1
    -1
      manifests/api/db.pp
  6. +1
    -1
      manifests/api/logging.pp
  7. +1
    -1
      manifests/backend/cinder.pp
  8. +1
    -1
      manifests/backend/file.pp
  9. +1
    -1
      manifests/backend/multistore/cinder.pp
  10. +1
    -1
      manifests/backend/multistore/file.pp
  11. +2
    -2
      manifests/backend/multistore/rbd.pp
  12. +2
    -2
      manifests/backend/multistore/swift.pp
  13. +1
    -1
      manifests/backend/multistore/vsphere.pp
  14. +2
    -2
      manifests/backend/rbd.pp
  15. +2
    -2
      manifests/backend/swift.pp
  16. +1
    -1
      manifests/backend/vsphere.pp
  17. +2
    -2
      manifests/cache/cleaner.pp
  18. +1
    -1
      manifests/cache/logging.pp
  19. +2
    -2
      manifests/cache/pruner.pp
  20. +2
    -2
      manifests/client.pp
  21. +1
    -1
      manifests/config.pp
  22. +2
    -2
      manifests/db/metadefs.pp
  23. +1
    -1
      manifests/db/mysql.pp
  24. +1
    -1
      manifests/db/postgresql.pp
  25. +1
    -1
      manifests/db/sync.pp
  26. +2
    -2
      manifests/init.pp
  27. +1
    -1
      manifests/keystone/auth.pp
  28. +1
    -1
      manifests/notify/rabbitmq.pp
  29. +1
    -1
      manifests/params.pp
  30. +2
    -2
      manifests/policy.pp
  31. +3
    -3
      manifests/registry.pp
  32. +1
    -1
      manifests/registry/authtoken.pp
  33. +1
    -1
      manifests/registry/db.pp
  34. +1
    -1
      manifests/registry/logging.pp
  35. +5
    -5
      spec/acceptance/basic_glance_spec.rb
  36. +1
    -1
      spec/classes/glance_api_spec.rb
  37. +1
    -1
      spec/classes/glance_backend_swift_spec.rb
  38. +1
    -1
      spec/classes/glance_keystone_auth_spec.rb
  39. +1
    -1
      spec/defines/glance_backend_multistore_swift_spec.rb

+ 3
- 3
examples/glance_multi_store.pp View File

@ -7,17 +7,17 @@
# default_store is set at that point, then the first store in the list 'stores'
# provided will be made the default).
class { '::glance::backend::file':
class { 'glance::backend::file':
multi_store => true,
}
class { '::glance::backend::swift':
class { 'glance::backend::swift':
swift_store_user => 'demo',
swift_store_key => 'secrete',
multi_store => true,
}
class { '::glance::api':
class { 'glance::api':
keystone_password => 'a_big_secret',
stores => ['file', 'swift'],
default_store => 'swift',


+ 2
- 2
examples/glance_single_store.pp View File

@ -7,12 +7,12 @@
# or it will attempt to override the default set by the backend class and result
# in an error.
class { '::glance::backend::swift':
class { 'glance::backend::swift':
swift_store_user => 'demo',
swift_store_key => 'secrete',
}
class { '::glance::api':
class { 'glance::api':
keystone_password => 'a_big_secret',
stores => ['swift'],
}

+ 6
- 6
manifests/api.pp View File

@ -387,13 +387,13 @@ class glance::api(
$multi_store = false,
) inherits glance {
include ::glance::deps
include ::glance::policy
include ::glance::api::db
include glance::deps
include glance::policy
include glance::api::db
if $sync_db {
include ::glance::db::sync
include ::glance::db::metadefs
include glance::db::sync
include glance::db::metadefs
}
if ( $glance::params::api_package_name != $glance::params::registry_package_name ) {
@ -597,7 +597,7 @@ enabled_backends instead.')
# keystone config
if $auth_strategy == 'keystone' {
include ::glance::api::authtoken
include glance::api::authtoken
}
oslo::middleware { 'glance_api_config':


+ 1
- 1
manifests/api/authtoken.pp View File

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


+ 1
- 1
manifests/api/db.pp View File

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


+ 1
- 1
manifests/api/logging.pp View File

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


+ 1
- 1
manifests/backend/cinder.pp View File

@ -86,7 +86,7 @@ class glance::backend::cinder(
$multi_store = false,
) {
include ::glance::deps
include glance::deps
warning('glance::backend::cinder is deprecated. Use glance::backend::multistore::cinder instead.')


+ 1
- 1
manifests/backend/file.pp View File

@ -18,7 +18,7 @@ class glance::backend::file(
$multi_store = false,
) {
include ::glance::deps
include glance::deps
warning('glance::backend::file is deprecated. Use glance::backend::multistore::file instead.')


+ 1
- 1
manifests/backend/multistore/cinder.pp View File

@ -84,7 +84,7 @@ define glance::backend::multistore::cinder(
$store_description = $::os_service_default,
) {
include ::glance::deps
include glance::deps
glance_api_config {
"${name}/cinder_api_insecure": value => $cinder_api_insecure;


+ 1
- 1
manifests/backend/multistore/file.pp View File

@ -33,7 +33,7 @@ define glance::backend::multistore::file(
$store_description = $::os_service_default,
) {
include ::glance::deps
include glance::deps
glance_api_config {
"${name}/filesystem_store_datadir": value => $filesystem_store_datadir;


+ 2
- 2
manifests/backend/multistore/rbd.pp View File

@ -63,8 +63,8 @@ define glance::backend::multistore::rbd(
$store_description = $::os_service_default,
) {
include ::glance::deps
include ::glance::params
include glance::deps
include glance::params
glance_api_config {
"${name}/rbd_store_ceph_conf": value => $rbd_store_ceph_conf;


+ 2
- 2
manifests/backend/multistore/swift.pp View File

@ -93,8 +93,8 @@ define glance::backend::multistore::swift(
$store_description = $::os_service_default,
) {
include ::glance::deps
include ::swift::client
include glance::deps
include swift::client
Class['swift::client'] -> Anchor['glance::install::end']
Service<| tag == 'swift-service' |> -> Service['glance-api']


+ 1
- 1
manifests/backend/multistore/vsphere.pp View File

@ -90,7 +90,7 @@ define glance::backend::multistore::vsphere(
$store_description = $::os_service_default,
) {
include ::glance::deps
include glance::deps
glance_api_config {
"${name}/vmware_insecure": value => $vmware_insecure;


+ 2
- 2
manifests/backend/rbd.pp View File

@ -47,8 +47,8 @@ class glance::backend::rbd(
$multi_store = false,
) {
include ::glance::deps
include ::glance::params
include glance::deps
include glance::params
warning('glance::backend::rbd is deprecated. Use glance::backend::multistore::rbd instead.')


+ 2
- 2
manifests/backend/swift.pp View File

@ -73,8 +73,8 @@ class glance::backend::swift(
$multi_store = false,
) {
include ::glance::deps
include ::swift::client
include glance::deps
include swift::client
warning('glance::backend::swift is deprecated. Use glance::backend::multistore::swift instead.')


+ 1
- 1
manifests/backend/vsphere.pp View File

@ -91,7 +91,7 @@ class glance::backend::vsphere(
$multi_store = false,
) {
include ::glance::deps
include glance::deps
warning('glance::backend::vsphere is deprecated. Use glance::backend::multistore::vsphere instead.')


+ 2
- 2
manifests/cache/cleaner.pp View File

@ -33,8 +33,8 @@ class glance::cache::cleaner(
$command_options = '',
) {
include ::glance::deps
include ::glance::params
include glance::deps
include glance::params
cron { 'glance-cache-cleaner':
command => "${glance::params::cache_cleaner_command} ${command_options}",


+ 1
- 1
manifests/cache/logging.pp View File

@ -114,7 +114,7 @@ class glance::cache::logging(
$log_date_format = $::os_service_default,
) {
include ::glance::deps
include glance::deps
oslo::log { 'glance_cache_config':
debug => $debug,


+ 2
- 2
manifests/cache/pruner.pp View File

@ -33,8 +33,8 @@ class glance::cache::pruner(
$command_options = '',
) {
include ::glance::deps
include ::glance::params
include glance::deps
include glance::params
cron { 'glance-cache-pruner':
command => "${glance::params::cache_pruner_command} ${command_options}",


+ 2
- 2
manifests/client.pp View File

@ -10,8 +10,8 @@ class glance::client(
$ensure = 'present'
) {
include ::glance::deps
include ::glance::params
include glance::deps
include glance::params
package { 'python-glanceclient':
ensure => $ensure,


+ 1
- 1
manifests/config.pp View File

@ -47,7 +47,7 @@ class glance::config (
$image_import_config = {},
) {
include ::glance::deps
include glance::deps
validate_legacy(Hash, 'validate_hash', $api_config)
validate_legacy(Hash, 'validate_hash', $api_paste_ini_config)


+ 2
- 2
manifests/db/metadefs.pp View File

@ -13,8 +13,8 @@ class glance::db::metadefs(
$extra_params = '',
) {
include ::glance::deps
include ::glance::params
include glance::deps
include glance::params
exec { 'glance-manage db_load_metadefs':
command => "glance-manage ${extra_params} db_load_metadefs",


+ 1
- 1
manifests/db/mysql.pp View File

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


+ 1
- 1
manifests/db/postgresql.pp View File

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


+ 1
- 1
manifests/db/sync.pp View File

@ -13,7 +13,7 @@ class glance::db::sync(
$extra_params = '',
) {
include ::glance::deps
include glance::deps
exec { 'glance-manage db_sync':
command => "glance-manage ${extra_params} db_sync",


+ 2
- 2
manifests/init.pp View File

@ -13,8 +13,8 @@ class glance(
$package_ensure = 'present'
) {
include ::glance::deps
include ::glance::params
include glance::deps
include glance::params
if ( $glance::params::api_package_name == $glance::params::registry_package_name ) {
package { $::glance::params::api_package_name :


+ 1
- 1
manifests/keystone/auth.pp View File

@ -88,7 +88,7 @@ class glance::keystone::auth(
$internal_url = 'http://127.0.0.1:9292',
) {
include ::glance::deps
include glance::deps
if $configure_endpoint {
Keystone_endpoint["${region}/${service_name}::${service_type}"] ~> Anchor['glance::service::begin']


+ 1
- 1
manifests/notify/rabbitmq.pp View File

@ -130,7 +130,7 @@ class glance::notify::rabbitmq(
$notification_driver = $::os_service_default,
) {
include ::glance::deps
include glance::deps
oslo::messaging::rabbit { ['glance_api_config', 'glance_registry_config']:
rabbit_ha_queues => $rabbit_ha_queues,


+ 1
- 1
manifests/params.pp View File

@ -1,7 +1,7 @@
# these parameters need to be accessed from several locations and
# should be considered to be constant
class glance::params {
include ::openstacklib::defaults
include openstacklib::defaults
$pyvers = $::openstacklib::defaults::pyvers
$client_package_name = "python${pyvers}-glanceclient"


+ 2
- 2
manifests/policy.pp View File

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


+ 3
- 3
manifests/registry.pp View File

@ -120,8 +120,8 @@ class glance::registry(
$enable_v1_registry = false,
) inherits glance {
include ::glance::deps
include ::glance::registry::db
include glance::deps
include glance::registry::db
if ( $glance::params::api_package_name != $glance::params::registry_package_name ) {
ensure_packages($glance::params::registry_package_name,
@ -159,7 +159,7 @@ class glance::registry(
# keystone config
if $auth_strategy == 'keystone' {
include ::glance::registry::authtoken
include glance::registry::authtoken
}
# SSL Options


+ 1
- 1
manifests/registry/authtoken.pp View File

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


+ 1
- 1
manifests/registry/db.pp View File

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


+ 1
- 1
manifests/registry/logging.pp View File

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


+ 5
- 5
spec/acceptance/basic_glance_spec.rb View File

@ -4,11 +4,11 @@ describe 'glance class' do
context 'default parameters' do
pp= <<-EOS
include ::openstack_integration
include ::openstack_integration::repos
include ::openstack_integration::mysql
include ::openstack_integration::keystone
include ::openstack_integration::glance
include openstack_integration
include openstack_integration::repos
include openstack_integration::mysql
include openstack_integration::keystone
include openstack_integration::glance
glance_image { 'test_image':
ensure => present,


+ 1
- 1
spec/classes/glance_api_spec.rb View File

@ -2,7 +2,7 @@ require 'spec_helper'
describe 'glance::api' do
let :pre_condition do
"class { '::glance::api::authtoken':
"class { 'glance::api::authtoken':
password => 'ChangeMe',
}"
end


+ 1
- 1
spec/classes/glance_backend_swift_spec.rb View File

@ -11,7 +11,7 @@ describe 'glance::backend::swift' do
let :pre_condition do
'class { "glance::api::authtoken": password => "pass" }
include ::glance::api'
include glance::api'
end
describe 'when default parameters' do


+ 1
- 1
spec/classes/glance_keystone_auth_spec.rb View File

@ -129,7 +129,7 @@ describe 'glance::keystone::auth' do
describe 'when configuring glance-api and the keystone endpoint' do
let :pre_condition do
"class { 'glance::api::authtoken': password => 'test' }
include ::glance::api"
include glance::api"
end
let :params do


+ 1
- 1
spec/defines/glance_backend_multistore_swift_spec.rb View File

@ -31,7 +31,7 @@ describe 'glance::backend::multistore::swift' do
let :pre_condition do
'class { "glance::api::authtoken": password => "pass" }
include ::glance::api'
include glance::api'
end
describe 'when default parameters' do


Loading…
Cancel
Save