Added task to create a ScaleIO volume type with required extra specs
Change-Id: Ica30f4d14c8489f9bf96dc3e36fcf9d8b88450e5
This commit is contained in:
parent
10fc8e7172
commit
a58ee7eac8
|
@ -0,0 +1,2 @@
|
|||
$fuel_settings = parseyaml(file('/etc/astute.yaml'))
|
||||
class {'scaleio_fuel::create_volume_type': }
|
|
@ -0,0 +1,19 @@
|
|||
class scaleio_fuel::create_volume_type {
|
||||
|
||||
$scaleio = $::fuel_settings['scaleio']
|
||||
$protection_domain = $scaleio['protection_domain']
|
||||
$storage_pool = $scaleio['storage_pool']
|
||||
$volume_type = 'sio_thin'
|
||||
|
||||
exec { "Create Cinder volume type \'${volume_type}\'":
|
||||
command => "bash -c 'source /root/openrc; cinder type-create ${volume_type}'",
|
||||
path => ['/usr/bin', '/bin'],
|
||||
unless => "bash -c 'source /root/openrc; cinder type-list |grep -q \" ${volume_type} \"'",
|
||||
} ->
|
||||
|
||||
exec { "Create Cinder volume type extra specs for \'${volume_type}\'":
|
||||
command => "bash -c 'source /root/openrc; cinder type-key ${volume_type} set sio:pd_name=${protection_domain} sio:provisioning_type=thin sio:sp_name=${storage_pool}'",
|
||||
path => ['/usr/bin', '/bin'],
|
||||
onlyif => "bash -c 'source /root/openrc; cinder type-list |grep -q \" ${volume_type} \"'",
|
||||
}
|
||||
}
|
28
tasks.yaml
28
tasks.yaml
|
@ -14,18 +14,42 @@
|
|||
puppet_modules: puppet/modules:/etc/puppet/modules
|
||||
timeout: 1800
|
||||
|
||||
- role: ['compute']
|
||||
- role: '*'
|
||||
stage: post_deployment/2100
|
||||
type: puppet
|
||||
parameters:
|
||||
puppet_manifest: puppet/manifests/gateway_configuration.pp
|
||||
puppet_modules: puppet/modules:/etc/puppet/modules
|
||||
timeout: 600
|
||||
|
||||
- role: ['compute']
|
||||
stage: post_deployment/2150
|
||||
type: puppet
|
||||
parameters:
|
||||
puppet_manifest: puppet/manifests/compute.pp
|
||||
puppet_modules: puppet/modules:/etc/puppet/modules
|
||||
timeout: 600
|
||||
|
||||
- role: ['primary-controller', 'controller']
|
||||
stage: post_deployment/2150
|
||||
stage: post_deployment/2200
|
||||
type: puppet
|
||||
parameters:
|
||||
puppet_manifest: puppet/manifests/controller.pp
|
||||
puppet_modules: puppet/modules:/etc/puppet/modules
|
||||
timeout: 600
|
||||
|
||||
# - role: ['primary-controller']
|
||||
# stage: post_deployment/2250
|
||||
# type: puppet
|
||||
# parameters:
|
||||
# puppet_manifest: puppet/manifests/enable_ha.pp
|
||||
# puppet_modules: puppet/modules:/etc/puppet/modules
|
||||
# timeout: 600
|
||||
|
||||
- role: ['primary-controller']
|
||||
stage: post_deployment/2300
|
||||
type: puppet
|
||||
parameters:
|
||||
puppet_manifest: puppet/manifests/create_volume_type.pp
|
||||
puppet_modules: puppet/modules:/etc/puppet/modules
|
||||
timeout: 600
|
||||
|
|
Loading…
Reference in New Issue