Add snapshorts directory config option
Change-Id: Ifba4f0738113341db54d1abd9919bc8c2327961b
This commit is contained in:
parent
170684de1b
commit
ea62370b1e
@ -44,6 +44,11 @@
|
||||
# have a preference and only operate on raw or qcow2
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*snapshots_directory*]
|
||||
# (optional) Location where libvirt driver will store snapshots before
|
||||
# uploading them to image service
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*disk_cachemodes*]
|
||||
# (optional) A list of cachemodes for different disk types, e.g.
|
||||
# ["file=directsync", "block=none"]
|
||||
@ -291,6 +296,7 @@ class nova::compute::libvirt (
|
||||
$cpu_models = [],
|
||||
$cpu_model_extra_flags = undef,
|
||||
$snapshot_image_format = $::os_service_default,
|
||||
$snapshots_directory = $::os_service_default,
|
||||
$disk_cachemodes = [],
|
||||
$hw_disk_discard = $::os_service_default,
|
||||
$hw_machine_type = $::os_service_default,
|
||||
@ -556,6 +562,7 @@ in a future release. Use the enabled_perf_events parameter instead')
|
||||
'libvirt/virt_type': value => $virt_type_real;
|
||||
'libvirt/cpu_mode': value => $cpu_mode_default;
|
||||
'libvirt/snapshot_image_format': value => $snapshot_image_format_real;
|
||||
'libvirt/snapshots_directory': value => $snapshots_directory;
|
||||
'libvirt/inject_password': value => $inject_password_real;
|
||||
'libvirt/inject_key': value => $inject_key_real;
|
||||
'libvirt/inject_partition': value => $inject_partition_real;
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
features:
|
||||
- |
|
||||
Add the parameter ``snapshots_directory`` to specify the location where
|
||||
libvirt driver will store snapshots before uploading them to image service.
|
@ -53,6 +53,7 @@ describe 'nova::compute::libvirt' do
|
||||
it { is_expected.to contain_nova_config('libvirt/cpu_model').with_ensure('absent')}
|
||||
it { is_expected.to contain_nova_config('libvirt/cpu_model_extra_flags').with_ensure('absent')}
|
||||
it { is_expected.to contain_nova_config('libvirt/snapshot_image_format').with_value('<SERVICE DEFAULT>')}
|
||||
it { is_expected.to contain_nova_config('libvirt/snapshots_directory').with_value('<SERVICE DEFAULT>')}
|
||||
it { is_expected.to contain_nova_config('libvirt/disk_cachemodes').with_ensure('absent')}
|
||||
it { is_expected.to contain_nova_config('libvirt/inject_password').with_value(false)}
|
||||
it { is_expected.to contain_nova_config('libvirt/inject_key').with_value(false)}
|
||||
@ -83,6 +84,7 @@ describe 'nova::compute::libvirt' do
|
||||
:cpu_models => ['kvm64', 'qemu64'],
|
||||
:cpu_model_extra_flags => 'pcid',
|
||||
:snapshot_image_format => 'raw',
|
||||
:snapshots_directory => '/var/lib/nova/snapshots',
|
||||
:disk_cachemodes => ['file=directsync','block=none'],
|
||||
:hw_disk_discard => 'unmap',
|
||||
:hw_machine_type => 'x86_64=machinetype1,armv7l=machinetype2',
|
||||
@ -121,6 +123,7 @@ describe 'nova::compute::libvirt' do
|
||||
it { is_expected.to contain_nova_config('libvirt/cpu_model').with_ensure('absent')}
|
||||
it { is_expected.to contain_nova_config('libvirt/cpu_model_extra_flags').with_value('pcid')}
|
||||
it { is_expected.to contain_nova_config('libvirt/snapshot_image_format').with_value('raw')}
|
||||
it { is_expected.to contain_nova_config('libvirt/snapshots_directory').with_value('/var/lib/nova/snapshots')}
|
||||
it { is_expected.to contain_nova_config('libvirt/disk_cachemodes').with_value('file=directsync,block=none')}
|
||||
it { is_expected.to contain_nova_config('libvirt/hw_disk_discard').with_value('unmap')}
|
||||
it { is_expected.to contain_nova_config('libvirt/hw_machine_type').with_value('x86_64=machinetype1,armv7l=machinetype2')}
|
||||
|
Loading…
x
Reference in New Issue
Block a user