Skip to content
Snippets Groups Projects
cinder.pp 2.31 KiB
Newer Older
  • Learn to ignore specific revisions
  • class iaas::profile::cinder (
      $password = undef,
    
      $public_interface = hiera('iaas::public_interface', undef),
    
      $admin_interface = hiera('iaas::admin_interface', undef),
    
      $secret = undef,
      $volume_size = undef,
    
    
    ##verbose, debug
    
      $verbose = hiera('iaas::verbose', undef),
      $debug = hiera('iaas::debug', undef),
    
    
      $region = hiera('iaas::region', undef),
      $endpoint = hiera('iaas::role::endpoint::main_address', undef),
    
      $rhosts = hiera('iaas::profile::rabbitmq::rhosts', undef),
    
      $rabbitmq_user = hiera('iaas::profile::rabbitmq::user', undef),
      $rabbitmq_password = hiera('iaas::profile::rabbitmq::password', undef),
    ) {
    
      include iaas::resources::connectors
    
    ##Leave commented if database is different from controller
    #  iaas::resources::database { 'cinder': }
    
    ##Verbose, debug
    
        verbose => $verbose,
        debug => $debug,
    
    
        database_connection => $iaas::resources::connectors::cinder,
    
    ##Added rabbit_hosts - uncomment as needed
    
    #    rabbit_host => $endpoint,
        rabbit_hosts => $rhosts,
    
        rabbit_userid => $rabbitmq_user,
        rabbit_password => $rabbitmq_password,
        mysql_module => '2.3',
    
      }
    
      class { '::cinder::glance':
        glance_api_servers => [ "${endpoint}:9292" ],
      }
    
      class { '::cinder::keystone::auth':
        password => $password,
    
        public_address => $endpoint,
        admin_address => $endpoint,
        internal_address => $endpoint,
    
        region => $region,
      }
    
      class { '::cinder::api':
    
    #Identity_uri - planed to be implemented in Kilo
    #    keystone_identity_uri => "http://${endpoint}:35357",
    
        keystone_auth_host => $endpoint,
    
        keystone_auth_uri => "http://${endpoint}:5000/v2.0",
    
        bind_host => $::facts["ipaddress_${admin_interface}"],
    
    #    scheduler_driver => 'cinder.scheduler.simple.SimpleScheduler',
    
        scheduler_driver => 'cinder.scheduler.filter_scheduler.FilterScheduler',
    
    #  class { '::cinder::setup_test_volume':
    #    volume_name => 'cinder-volumes',
    #    size => $volume_size
    #  } ->
    
    
      class { '::cinder::volume': }
    
    
      class { '::cinder::volume::rbd':
        rbd_pool => 'volumes',
        rbd_user => 'cinder',
    
      class { '::cinder::backup': }
      class { '::cinder::backup::ceph':
        backup_ceph_user => 'cinder-backup',
      }