diff --git a/docs/suse caasp/README.md b/docs/suse caasp/README.md index f396cb7b..a702ead4 100644 --- a/docs/suse caasp/README.md +++ b/docs/suse caasp/README.md @@ -144,7 +144,7 @@ Installing the HPE 3PAR Volume Plug-in for Docker (Containerized Plug-in) for SU -4. Either you can build the container image by following instructions in step 5 below, or use an pre-existing 2.1 image of the plugin container by substituting `image: hpestorage/legacyvolumeplugin:2.1` in docker-compose.yml given in step 6 +4. Either you can build the container image by following instructions in step 5 below, or use an pre-existing 2.1 image of the plugin container by substituting `image: hpestorage/legacyvolumeplugin:2.1-suse` in docker-compose.yml given in step 6 5. **Build the containerized image** ```bash @@ -173,6 +173,7 @@ Installing the HPE 3PAR Volume Plug-in for Docker (Containerized Plug-in) for SU image: hpe-storage/python-hpedockerplugin:plugin_v2 container_name: volplugin net: host + restart: always privileged: true volumes: - /dev:/dev diff --git a/hpedockerplugin/volume_manager.py b/hpedockerplugin/volume_manager.py index ff503902..ca986592 100644 --- a/hpedockerplugin/volume_manager.py +++ b/hpedockerplugin/volume_manager.py @@ -1043,18 +1043,13 @@ def get_volume_snap_details(self, volname, snapname, qualified_name): vol_detail['fsMode'] = volinfo.get('fsMode') vol_detail['mountConflictDelay'] = volinfo.get( 'mount_conflict_delay') - - cpg = volinfo.get('cpg') - snap_cpg = volinfo.get('snap_cpg') - rcg_info = volinfo.get('rcg_info') - if rcg_info: - driver = self._get_target_driver(rcg_info) - if driver == self._remote_driver: - cpg = self.tgt_bkend_config['hpe3par_cpg'] - snap_cpg = self.tgt_bkend_config['hpe3par_snapcpg'] - - vol_detail['cpg'] = cpg - vol_detail['snap_cpg'] = snap_cpg + vol_detail['cpg'] = volinfo.get('cpg') + vol_detail['snap_cpg'] = volinfo.get('snap_cpg') + if volinfo.get('rcg_info'): + vol_detail['secondary_cpg'] = \ + self.tgt_bkend_config.hpe3par_cpg[0] + vol_detail['secondary_snap_cpg'] = \ + self.tgt_bkend_config.hpe3par_snapcpg[0] volume['Status'].update({'volume_detail': vol_detail}) response = json.dumps({u"Err": err, u"Volume": volume})