From 91e8ed328a4292c2450ba7b1fb2ddb6d4d82a229 Mon Sep 17 00:00:00 2001 From: Emilien Macchi Date: Mon, 9 Sep 2019 18:39:22 -0400 Subject: [PATCH] Support deploying multiple Cinder Pure Storage backends CinderPureBackendName is enhanced to support a list of backend names, and a new CinderPureMultiConfig parameter provides a way to specify parameter values for each backend. For example: parameter_defaults: CinderEnableIscsiBackend: false CinderEnablePureBackend: true CinderPureBackendName: - tripleo_pure_1 - tripleo_pure_2 # These will be the default parameter values for each backend. CinderPureStorageProtocol: 'iSCSI' CinderPureUseChap: false CinderPureMultipathXfer: true CinderPureImageCache: true # Use CinderPureMultiConfig to override values in specific backends. CinderPureMultiConfig: tripleo_pure_1: CinderPureSanIp: '10.0.0.1' CinderPureAPIToken: 'secret' tripleo_pure_2: CinderPureSanIp: '10.0.0.2' CinderPureAPIToken: 'anothersecret' # This will take precedence over the default value. CinderPureUseChap: true Co-Authored-By: Alan Bishop Depends-On: Ia7cc82f5eb4e228a43e47624d87e319ac5340268 Change-Id: I1083ef9893dede234b4cafd9888c898fa0e31077 --- .../cinder/cinder-backend-pure-puppet.yaml | 11 ++++++++++- environments/cinder-pure-config.yaml | 17 +++++++++++++++++ ...multiple-pure-backends-4537532f428315e1.yaml | 7 +++++++ 3 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/cinder-multiple-pure-backends-4537532f428315e1.yaml diff --git a/deployment/cinder/cinder-backend-pure-puppet.yaml b/deployment/cinder/cinder-backend-pure-puppet.yaml index 0805c44017..bbd79ed18a 100644 --- a/deployment/cinder/cinder-backend-pure-puppet.yaml +++ b/deployment/cinder/cinder-backend-pure-puppet.yaml @@ -47,8 +47,16 @@ parameters: type: boolean default: true CinderPureBackendName: - type: string + type: comma_delimited_list default: 'tripleo_pure' + description: A list of Cinder Pure Storage backend names. + CinderPureMultiConfig: + type: json + default: {} + description: > + Dictionary of settings when configuring multiple Pure backends. The + hash key is the backend name, and the value is a dictionary of parameter + values unique to that backend. CinderPureAvailabilityZone: default: '' description: > @@ -81,6 +89,7 @@ outputs: map_merge: - tripleo::profile::base::cinder::volume::cinder_enable_pure_backend: {get_param: CinderEnablePureBackend} cinder::backend::pure::volume_backend_name: {get_param: CinderPureBackendName} + cinder::backend::pure::volume_multi_config: {get_param: CinderPureMultiConfig} cinder::backend::pure::pure_storage_protocol: {get_param: CinderPureStorageProtocol} cinder::backend::pure::san_ip: {get_param: CinderPureSanIp} cinder::backend::pure::pure_api_token: {get_param: CinderPureAPIToken} diff --git a/environments/cinder-pure-config.yaml b/environments/cinder-pure-config.yaml index 3c3b792c79..230eb6d340 100644 --- a/environments/cinder-pure-config.yaml +++ b/environments/cinder-pure-config.yaml @@ -7,9 +7,26 @@ parameter_defaults: CinderEnableIscsiBackend: false CinderEnablePureBackend: true CinderPureBackendName: 'tripleo_pure' + CinderPureMultiConfig: {} + CinderPureAvailabilityZone: '' CinderPureStorageProtocol: 'iSCSI' CinderPureSanIp: '' CinderPureAPIToken: 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' CinderPureUseChap: false CinderPureMultipathXfer: true CinderPureImageCache: true + +# To configure multiple Pure backends, use CinderPureMultiConfig to +# assign parameter values specific to that backend. For example: +# CinderPureBackendName: +# - tripleo_pure_1 +# - tripleo_pure_2 +# CinderPureUseChap: false # Default value for the Pure backends +# CinderPureMultiConfig: +# tripleo_pure_1: +# CinderPureSanIp: '10.0.0.1' +# CinderPureAPIToken: 'secret' +# tripleo_pure_2: +# CinderPureSanIp: '10.0.0.2' +# CinderPureAPIToken: 'anothersecret' +# CinderPureUseChap: true # Specific value for this backend diff --git a/releasenotes/notes/cinder-multiple-pure-backends-4537532f428315e1.yaml b/releasenotes/notes/cinder-multiple-pure-backends-4537532f428315e1.yaml new file mode 100644 index 0000000000..cbf65470a5 --- /dev/null +++ b/releasenotes/notes/cinder-multiple-pure-backends-4537532f428315e1.yaml @@ -0,0 +1,7 @@ +--- +features: + - | + Support deploying multiple Cinder Pure Storage backends. + CinderPureBackendName is enhanced to support a list of backend names, and + a new CinderPureMultiConfig parameter provides a way to specify parameter + values for each backend.