From 639285f0915796be53315d92156f72e756a5a21b Mon Sep 17 00:00:00 2001 From: Alan Bishop Date: Thu, 24 Jan 2019 15:39:00 -0500 Subject: [PATCH] Update parameters for cinder's Netapp backend Update THT to align with puppet-tripleo changes made in [1] - Add new CinderNetappPoolNameSearchPattern parameter - Deprecate CinderNetappStoragePools parameter - Remove previously deprecated CinderNetappEseriesHostType parameter [1] https://review.openstack.org/570406 Fix relative path in file the sample-env-generator uses to generate environments/storage/cinder-netapp-config.yaml. Change-Id: I813ca60eb5ce9e008e1b72e88d83709d3125676f --- .../cinder/cinder-backend-netapp-puppet.yaml | 22 ++++++++++++++----- environments/cinder-netapp-config.yaml | 2 +- .../storage/cinder-netapp-config.yaml | 10 ++++----- ...er-netapp-parameters-cf6da846e72007df.yaml | 11 ++++++++++ sample-env-generator/storage.yaml | 2 +- 5 files changed, 34 insertions(+), 13 deletions(-) create mode 100644 releasenotes/notes/update-cinder-netapp-parameters-cf6da846e72007df.yaml diff --git a/deployment/cinder/cinder-backend-netapp-puppet.yaml b/deployment/cinder/cinder-backend-netapp-puppet.yaml index 5a3cf5fbbc..5fe5a0374d 100644 --- a/deployment/cinder/cinder-backend-netapp-puppet.yaml +++ b/deployment/cinder/cinder-backend-netapp-puppet.yaml @@ -94,9 +94,13 @@ parameters: type: string default: '' hidden: true - CinderNetappStoragePools: + CinderNetappPoolNameSearchPattern: + default: '(.+)' + description: > + Regular expression that will be applied to the names of FlexVol volumes + in the Netapp backend that represent pools in Cinder. It may be used + to restrict provisioning to the specified FlexVol volumes. type: string - default: '' CinderNetappHostType: type: string default: '' @@ -110,15 +114,15 @@ parameters: type: string default: 'false' # DEPRECATED options for compatibility with older versions - CinderNetappEseriesHostType: + CinderNetappStoragePools: type: string - default: 'linux_dm_mp' + default: '' parameter_groups: - label: deprecated description: Do not use deprecated params, they will be removed. parameters: - - CinderNetappEseriesHostType + - CinderNetappStoragePools outputs: role_data: @@ -147,7 +151,6 @@ outputs: cinder::backend::netapp::netapp_copyoffload_tool_path: {get_param: CinderNetappCopyOffloadToolPath} cinder::backend::netapp::netapp_controller_ips: {get_param: CinderNetappControllerIps} cinder::backend::netapp::netapp_sa_password: {get_param: CinderNetappSaPassword} - cinder::backend::netapp::netapp_storage_pools: {get_param: CinderNetappStoragePools} cinder::backend::netapp::netapp_host_type: {get_param: CinderNetappHostType} cinder::backend::netapp::netapp_webservice_path: {get_param: CinderNetappWebservicePath} cinder::backend::netapp::nas_secure_file_operations: {get_param: CinderNetappNasSecureFileOperations} @@ -157,3 +160,10 @@ outputs: - {equals : [{get_param: CinderNetappAvailabilityZone}, '']} - {} - cinder::backend::netapp::backend_availability_zone: {get_param: CinderNetappAvailabilityZone} + - + # Prefer CinderNetappPoolNameSearchPattern unless the (deprecated) + # CinderNetappStoragePools has a non-empty value. + if: + - {equals : [{get_param: CinderNetappStoragePools}, '']} + - cinder::backend::netapp::netapp_pool_name_search_pattern: {get_param: CinderNetappPoolNameSearchPattern} + - cinder::backend::netapp::netapp_storage_pools: {get_param: CinderNetappStoragePools} diff --git a/environments/cinder-netapp-config.yaml b/environments/cinder-netapp-config.yaml index 37aa233caf..d2ebfce2eb 100644 --- a/environments/cinder-netapp-config.yaml +++ b/environments/cinder-netapp-config.yaml @@ -24,6 +24,6 @@ parameter_defaults: CinderNetappCopyOffloadToolPath: '' CinderNetappControllerIps: '' CinderNetappSaPassword: '' - CinderNetappStoragePools: '' + CinderNetappPoolNameSearchPattern: '(.+)' CinderNetappHostType: '' CinderNetappWebservicePath: '/devmgr/v2' diff --git a/environments/storage/cinder-netapp-config.yaml b/environments/storage/cinder-netapp-config.yaml index 88ed13b259..ce84e3bb78 100644 --- a/environments/storage/cinder-netapp-config.yaml +++ b/environments/storage/cinder-netapp-config.yaml @@ -25,10 +25,6 @@ parameter_defaults: # Type: string CinderNetappCopyOffloadToolPath: '' - # - # Type: string - CinderNetappEseriesHostType: linux_dm_mp - # # Type: string CinderNetappHostType: '' @@ -67,6 +63,10 @@ parameter_defaults: # Type: string CinderNetappPassword: + # Regular expression that will be applied to the names of FlexVol volumes in the Netapp backend that represent pools in Cinder. It may be used to restrict provisioning to the specified FlexVol volumes. + # Type: string + CinderNetappPoolNameSearchPattern: (.+) + # # Type: string CinderNetappSaPassword: '' @@ -128,4 +128,4 @@ parameter_defaults: # End static parameters # ********************* resource_registry: - OS::TripleO::Services::CinderBackendNetApp: ../deployment/cinder/cinder-backend-netapp-puppet.yaml + OS::TripleO::Services::CinderBackendNetApp: ../../deployment/cinder/cinder-backend-netapp-puppet.yaml diff --git a/releasenotes/notes/update-cinder-netapp-parameters-cf6da846e72007df.yaml b/releasenotes/notes/update-cinder-netapp-parameters-cf6da846e72007df.yaml new file mode 100644 index 0000000000..08e6ee1769 --- /dev/null +++ b/releasenotes/notes/update-cinder-netapp-parameters-cf6da846e72007df.yaml @@ -0,0 +1,11 @@ +--- +features: + - | + Add new CinderNetappPoolNameSearchPattern parameter, which controls which + Netapp FlexVol volumes represent pools in Cinder. +deprecations: + - | + The CinderNetappStoragePools parameter is deprecated in favor of the new + CinderNetappPoolNameSearchPattern parameter. + The previously deprecated CinderNetappEseriesHostType parameter has been + removed. diff --git a/sample-env-generator/storage.yaml b/sample-env-generator/storage.yaml index 4feb700fbc..9f91671e7f 100644 --- a/sample-env-generator/storage.yaml +++ b/sample-env-generator/storage.yaml @@ -68,4 +68,4 @@ environments: static: - CinderEnableNetappBackend resource_registry: - OS::TripleO::Services::CinderBackendNetApp: ../deployment/cinder/cinder-backend-netapp-puppet.yaml + OS::TripleO::Services::CinderBackendNetApp: ../../deployment/cinder/cinder-backend-netapp-puppet.yaml