Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDK-352 : Add storage config params - block_volume_count and block_volume_size #274

Merged
merged 4 commits into from
May 21, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 14 additions & 3 deletions qds_sdk/cloud/oracle_bmc_cloud.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@ def set_cloud_config(self,
storage_tenant_id=None,
storage_user_id=None,
storage_key_finger_print=None,
storage_api_private_rsa_key=None):
storage_api_private_rsa_key=None,
block_volume_count=None,
block_volume_size=None):
'''

Args:
Expand Down Expand Up @@ -66,6 +68,10 @@ def set_cloud_config(self,

storage_api_private_rsa_key: storage api private rsa key for oracle cluster

block_volume_count: count of block volumes to be mounted to an instance as reserved disks

block_volume_size: It is the size (in GB) of each block volume to be mounted to an instance as reserved disk

'''

self.set_compute_config(use_account_compute_creds, compute_tenant_id,
Expand All @@ -75,7 +81,8 @@ def set_cloud_config(self,
self.set_network_config(vcn_id, subnet_id,
compartment_id, image_id, availability_domain_info_map)
self.set_storage_config(storage_tenant_id, storage_user_id,
storage_key_finger_print, storage_api_private_rsa_key)
storage_key_finger_print, storage_api_private_rsa_key, block_volume_count,
block_volume_size)

def set_compute_config(self,
use_account_compute_creds=None,
Expand Down Expand Up @@ -115,11 +122,15 @@ def set_storage_config(self,
storage_tenant_id=None,
storage_user_id=None,
storage_key_finger_print=None,
storage_api_private_rsa_key=None):
storage_api_private_rsa_key=None,
block_volume_count=None,
block_volume_size=None):
self.storage_config['storage_tenant_id'] = storage_tenant_id
self.storage_config['storage_user_id'] = storage_user_id
self.storage_config['storage_key_finger_print'] = storage_key_finger_print
self.storage_config['storage_api_private_rsa_key'] = storage_api_private_rsa_key
self.storage_config['block_volume_count'] = block_volume_count
self.storage_config['block_volume_size'] = block_volume_size

def set_cloud_config_from_arguments(self, arguments):
self.set_cloud_config(compute_tenant_id=arguments.compute_tenant_id,
Expand Down