INSTRUCTION
stringlengths
1
8.43k
RESPONSE
stringlengths
75
104k
Converts xml response to service bus namespace
def xml_to_namespace(xmlstr): '''Converts xml response to service bus namespace The xml format for namespace: <entry> <id>uuid:00000000-0000-0000-0000-000000000000;id=0000000</id> <title type="text">myunittests</title> <updated>2012-08-22T16:48:10Z</updated> <content type="application/xml"> <Namesp...
Converts xml response to service bus region
def xml_to_region(xmlstr): '''Converts xml response to service bus region The xml format for region: <entry> <id>uuid:157c311f-081f-4b4a-a0ba-a8f990ffd2a3;id=1756759</id> <title type="text"></title> <updated>2013-04-10T18:25:29Z</updated> <content type="application/xml"> <RegionCodeDescription ...
Converts xml response to service bus namespace availability
def xml_to_namespace_availability(xmlstr): '''Converts xml response to service bus namespace availability The xml format: <?xml version="1.0" encoding="utf-8"?> <entry xmlns="http://www.w3.org/2005/Atom"> <id>uuid:9fc7c652-1856-47ab-8d74-cd31502ea8e6;id=3683292</id> <title type="text"></title> ...
Convert odata type http:// www. odata. org/ documentation/ odata - version - 2 - 0/ overview#AbstractTypeSystem To be completed
def odata_converter(data, str_type): ''' Convert odata type http://www.odata.org/documentation/odata-version-2-0/overview#AbstractTypeSystem To be completed ''' if not str_type: return _str(data) if str_type in ["Edm.Single", "Edm.Double"]: return ...
Converts xml response to service bus metrics objects
def xml_to_metrics(xmlstr, object_type): '''Converts xml response to service bus metrics objects The xml format for MetricProperties <entry> <id>https://sbgm.windows.net/Metrics(\'listeners.active\')</id> <title/> <updated>2014-10-09T11:56:50Z</updated> <author> <name/> </au...
<CloudService xmlns: i = http:// www. w3. org/ 2001/ XMLSchema - instance xmlns = http:// schemas. microsoft. com/ windowsazure > <Label > MyApp3</ Label > <Description > My Cloud Service for app3</ Description > <GeoRegion > South Central US</ GeoRegion > </ CloudService >
def create_cloud_service_to_xml(label, description, geo_region): ''' <CloudService xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/windowsazure"> <Label>MyApp3</Label> <Description>My Cloud Service for app3</Description> <GeoRegion>So...
<Resource xmlns: i = http:// www. w3. org/ 2001/ XMLSchema - instance xmlns = http:// schemas. microsoft. com/ windowsazure > <IntrinsicSettings > <Plan > Standard</ Plan > <Quota > <MaxJobCount > 10</ MaxJobCount > <MaxRecurrence > <Frequency > Second</ Frequency > <Interval > 1</ Interval > </ MaxRecurrence > </ Quot...
def create_job_collection_to_xml(plan): ''' <Resource xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/windowsazure"> <IntrinsicSettings> <Plan>Standard</Plan> <Quota> <MaxJobCount>10</MaxJobCount> <Ma...
Instance depends on the API version:
def management_locks(self): """Instance depends on the API version: * 2015-01-01: :class:`ManagementLocksOperations<azure.mgmt.resource.locks.v2015_01_01.operations.ManagementLocksOperations>` * 2016-09-01: :class:`ManagementLocksOperations<azure.mgmt.resource.locks.v2016_09_01.operations...
Replaces the runbook draft content.
def replace_content( self, resource_group_name, automation_account_name, runbook_name, runbook_content, custom_headers=None, raw=False, callback=None, polling=True, **operation_config): """Replaces the runbook draft content. :param resource_group_name: Name of an Azure Resource group. ...
Get domain name recommendations based on keywords.
def list_recommendations( self, keywords=None, max_domain_recommendations=None, custom_headers=None, raw=False, **operation_config): """Get domain name recommendations based on keywords. Get domain name recommendations based on keywords. :param keywords: Keywords to be used for gen...
Asynchronous operation to modify a knowledgebase.
def update( self, kb_id, update_kb, custom_headers=None, raw=False, **operation_config): """Asynchronous operation to modify a knowledgebase. :param kb_id: Knowledgebase id. :type kb_id: str :param update_kb: Post body of the request. :type update_kb: ~azure...
Retrieve metric data.
def get( self, app_id, metric_id, timespan=None, interval=None, aggregation=None, segment=None, top=None, orderby=None, filter=None, custom_headers=None, raw=False, **operation_config): """Retrieve metric data. Gets metric values for a single metric. :param app_id: ID of the applic...
Retrieve metric data.
def get_multiple( self, app_id, body, custom_headers=None, raw=False, **operation_config): """Retrieve metric data. Gets metric values for multiple metrics. :param app_id: ID of the application. This is Application ID from the API Access settings blade in the Azure portal....
Register a renewable entity for automatic lock renewal.
def register(self, renewable, timeout=300): """Register a renewable entity for automatic lock renewal. :param renewable: A locked entity that needs to be renewed. :type renewable: ~azure.servicebus.aio.async_message.Message or ~azure.servicebus.aio.async_receive_handler.SessionReceiver...
Gets a collection that contains the object IDs of the groups of which the user is a member.
def get_member_groups( self, object_id, security_enabled_only, additional_properties=None, custom_headers=None, raw=False, **operation_config): """Gets a collection that contains the object IDs of the groups of which the user is a member. :param object_id: The object ID of the user ...
Will clone the given PR branch and vuild the package with the given name.
def build_package_from_pr_number(gh_token, sdk_id, pr_number, output_folder, *, with_comment=False): """Will clone the given PR branch and vuild the package with the given name.""" con = Github(gh_token) repo = con.get_repo(sdk_id) sdk_pr = repo.get_pull(pr_number) # "get_files" of Github only down...
Import data into Redis cache.
def import_data( self, resource_group_name, name, files, format=None, custom_headers=None, raw=False, polling=True, **operation_config): """Import data into Redis cache. :param resource_group_name: The name of the resource group. :type resource_group_name: str :param name: T...
: param collection: The resource collection type.: type collection: str: param vault: The vault URI.: type vault: str: param name: The resource name.: type name: str: param version: The resource version.: type version: str: rtype: KeyVaultId
def create_object_id(collection, vault, name, version): """ :param collection: The resource collection type. :type collection: str :param vault: The vault URI. :type vault: str :param name: The resource name. :type name: str :param version: The resource ve...
: param collection: The resource collection type.: type collection: str: param id: The resource uri.: type id: str: rtype: KeyVaultId
def parse_object_id(collection, id): """ :param collection: The resource collection type. :type collection: str :param id: The resource uri. :type id: str :rtype: KeyVaultId """ collection = _validate_string_argument(collection, 'collection') retur...
: param vault: The vault uri.: type vault: str: param name: The key name.: type name: str: param version: The key version.: type version: str: rtype: KeyVaultId
def create_key_id(vault, name, version=None): """ :param vault: The vault uri. :type vault: str :param name: The key name. :type name: str :param version: The key version. :type version: str :rtype: KeyVaultId """ return KeyId(vault=vault, ...
: param vault: The vault uri.: type vault: str: param name: The secret name.: type name: str: param version: The secret version.: type version: str: rtype: KeyVaultId
def create_secret_id(vault, name, version=None): """ :param vault: The vault uri. :type vault: str :param name: The secret name. :type name: str :param version: The secret version. :type version: str :rtype: KeyVaultId """ return SecretId(v...
: param vault: The vault uri.: type vault: str: param name: The certificate name.: type name: str: param version: The certificate version.: type version: str: rtype: KeyVaultId
def create_certificate_id(vault, name, version=None): """ :param vault: The vault uri. :type vault: str :param name: The certificate name. :type name: str :param version: The certificate version. :type version: str :rtype: KeyVaultId """ re...
Formats the KeyVaultIdentifier into a identifier uri based of the specified format string: param fmt: The format string for the identifier uri: return: The formatted key vault object identifier uri
def _format(self, fmt=None): """ Formats the KeyVaultIdentifier into a identifier uri based of the specified format string :param fmt: The format string for the identifier uri :return: The formatted key vault object identifier uri """ # if no fmt was specified use the _...
Parses the specified uri using _id_format as a format string and sets the parsed format arguments as attributes on the current id object.: param uri: The key vault identifier uri to be parsed: param validation_args: format arguments to be validated: return: None
def _parse(self, uri, validation_args): """ Parses the specified uri, using _id_format as a format string, and sets the parsed format arguments as attributes on the current id object. :param uri: The key vault identifier uri to be parsed :param validation_args: format arguments...
Publish runbook draft.
def publish( self, resource_group_name, automation_account_name, runbook_name, custom_headers=None, raw=False, polling=True, **operation_config): """Publish runbook draft. :param resource_group_name: Name of an Azure Resource group. :type resource_group_name: str :param auto...
Renew the message lock.
async def renew_lock(self): """Renew the message lock. This will maintain the lock on the message to ensure it is not returned to the queue to be reprocessed. In order to complete (or otherwise settle) the message, the lock must be maintained. Messages received via ReceiveAndDelete mode...
Move the message to the Dead Letter queue.
async def dead_letter(self, description=None): """Move the message to the Dead Letter queue. The Dead Letter queue is a sub-queue that can be used to store messages that failed to process correctly, or otherwise require further inspection or processing. The queue can also be configured ...
Abandon the message.
async def abandon(self): """Abandon the message. This message will be returned to the queue to be reprocessed. :raises: ~azure.servicebus.common.errors.MessageAlreadySettled if the message has been settled. :raises: ~azure.servicebus.common.errors.MessageLockExpired if message lock has...
Complete the message.
async def complete(self): """Complete the message. This removes the message from the queue. :raises: ~azure.servicebus.common.errors.MessageAlreadySettled if the message has been settled. :raises: ~azure.servicebus.common.errors.MessageLockExpired if message lock has already expired. ...
From a syntax like package_name#submodule build a package name and complete module name.
def parse_input(input_parameter): """From a syntax like package_name#submodule, build a package name and complete module name. """ split_package_name = input_parameter.split('#') package_name = split_package_name[0] module_name = package_name.replace("-", ".") if len(split_package_name) >= 2...
Will extract from __code__ the API version. Should be use if you use this is an operation group with no constant api_version.
def extract_api_version_from_code(function): """Will extract from __code__ the API version. Should be use if you use this is an operation group with no constant api_version. """ try: srccode = inspect.getsource(function) try: ast_tree = ast.parse(srccode) except Indentati...
Replace alterations data.
def replace( self, word_alterations, custom_headers=None, raw=False, **operation_config): """Replace alterations data. :param word_alterations: Collection of word alterations. :type word_alterations: list[~azure.cognitiveservices.knowledge.qnamaker.models.AlterationsDTO] ...
Adds the specified value as a new version of the specified secret resource.
def add_value( self, secret_resource_name, secret_value_resource_name, name, value=None, custom_headers=None, raw=False, **operation_config): """Adds the specified value as a new version of the specified secret resource. Creates a new value of the specified secret resource. The name...
Returns system properties for the specified storage account.
def get_storage_account_properties(self, service_name): ''' Returns system properties for the specified storage account. service_name: Name of the storage service account. ''' _validate_not_none('service_name', service_name) return self._perform_get(self._get...
Returns the primary and secondary access keys for the specified storage account.
def get_storage_account_keys(self, service_name): ''' Returns the primary and secondary access keys for the specified storage account. service_name: Name of the storage service account. ''' _validate_not_none('service_name', service_name) return self....
Regenerates the primary or secondary access key for the specified storage account.
def regenerate_storage_account_keys(self, service_name, key_type): ''' Regenerates the primary or secondary access key for the specified storage account. service_name: Name of the storage service account. key_type: Specifies which key to regenerate. Valid...
Creates a new storage account in Windows Azure.
def create_storage_account(self, service_name, description, label, affinity_group=None, location=None, geo_replication_enabled=None, extended_properties=None, account_type='Standard_GRS'): ...
Updates the label the description and enables or disables the geo - replication status for a storage account in Windows Azure.
def update_storage_account(self, service_name, description=None, label=None, geo_replication_enabled=None, extended_properties=None, account_type='Standard_GRS'): ''' Updates the label, the description, and enab...
Deletes the specified storage account from Windows Azure.
def delete_storage_account(self, service_name): ''' Deletes the specified storage account from Windows Azure. service_name: Name of the storage service account. ''' _validate_not_none('service_name', service_name) return self._perform_delete( self...
Checks to see if the specified storage account name is available or if it has already been taken.
def check_storage_account_name_availability(self, service_name): ''' Checks to see if the specified storage account name is available, or if it has already been taken. service_name: Name of the storage service account. ''' _validate_not_none('service_name', s...
Retrieves system properties for the specified hosted service. These properties include the service name and service type ; the name of the affinity group to which the service belongs or its location if it is not part of an affinity group ; and optionally information on the service s deployments.
def get_hosted_service_properties(self, service_name, embed_detail=False): ''' Retrieves system properties for the specified hosted service. These properties include the service name and service type; the name of the affinity group to which the service belongs, or its location if it is ...
Creates a new hosted service in Windows Azure.
def create_hosted_service(self, service_name, label, description=None, location=None, affinity_group=None, extended_properties=None): ''' Creates a new hosted service in Windows Azure. service_name: A name for the hosted se...
Updates the label and/ or the description for a hosted service in Windows Azure.
def update_hosted_service(self, service_name, label=None, description=None, extended_properties=None): ''' Updates the label and/or the description for a hosted service in Windows Azure. service_name: Name of the hosted service. label: ...
Deletes the specified hosted service from Windows Azure.
def delete_hosted_service(self, service_name, complete=False): ''' Deletes the specified hosted service from Windows Azure. service_name: Name of the hosted service. complete: True if all OS/data disks and the source blobs for the disks should also be...
Returns configuration information status and system properties for a deployment.
def get_deployment_by_slot(self, service_name, deployment_slot): ''' Returns configuration information, status, and system properties for a deployment. service_name: Name of the hosted service. deployment_slot: The environment to which the hosted service ...
Returns configuration information status and system properties for a deployment.
def get_deployment_by_name(self, service_name, deployment_name): ''' Returns configuration information, status, and system properties for a deployment. service_name: Name of the hosted service. deployment_name: The name of the deployment. ''' ...
Uploads a new service package and creates a new deployment on staging or production.
def create_deployment(self, service_name, deployment_slot, name, package_url, label, configuration, start_deployment=False, treat_warnings_as_error=False, extended_properties=None): ''' Uploads a new ...
Deletes the specified deployment.
def delete_deployment(self, service_name, deployment_name,delete_vhd=False): ''' Deletes the specified deployment. service_name: Name of the hosted service. deployment_name: The name of the deployment. ''' _validate_not_none('service_name', servic...
Initiates a virtual IP swap between the staging and production deployment environments for a service. If the service is currently running in the staging environment it will be swapped to the production environment. If it is running in the production environment it will be swapped to staging.
def swap_deployment(self, service_name, production, source_deployment): ''' Initiates a virtual IP swap between the staging and production deployment environments for a service. If the service is currently running in the staging environment, it will be swapped to the production e...
Initiates a change to the deployment configuration.
def change_deployment_configuration(self, service_name, deployment_name, configuration, treat_warnings_as_error=False, mode='Auto', extended_properties=None): ''' Initiates a change to...
Initiates a change in deployment status.
def update_deployment_status(self, service_name, deployment_name, status): ''' Initiates a change in deployment status. service_name: Name of the hosted service. deployment_name: The name of the deployment. status: The change to initiate to th...
Initiates an upgrade.
def upgrade_deployment(self, service_name, deployment_name, mode, package_url, configuration, label, force, role_to_upgrade=None, extended_properties=None): ''' Initiates an upgrade. service_name: Name of the hosted service. ...
Specifies the next upgrade domain to be walked during manual in - place upgrade or configuration change.
def walk_upgrade_domain(self, service_name, deployment_name, upgrade_domain): ''' Specifies the next upgrade domain to be walked during manual in-place upgrade or configuration change. service_name: Name of the hosted service. deployment_n...
Cancels an in progress configuration change ( update ) or upgrade and returns the deployment to its state before the upgrade or configuration change was started.
def rollback_update_or_upgrade(self, service_name, deployment_name, mode, force): ''' Cancels an in progress configuration change (update) or upgrade and returns the deployment to its state before the upgrade or configuration change was started. ...
Requests a reboot of a role instance that is running in a deployment.
def reboot_role_instance(self, service_name, deployment_name, role_instance_name): ''' Requests a reboot of a role instance that is running in a deployment. service_name: Name of the hosted service. deployment_name: The name of the de...
Reinstalls the operating system on instances of web roles or worker roles and initializes the storage resources that are used by them. If you do not want to initialize storage resources you can use reimage_role_instance.
def delete_role_instances(self, service_name, deployment_name, role_instance_names): ''' Reinstalls the operating system on instances of web roles or worker roles and initializes the storage resources that are used by them. If you do not want to initialize st...
Checks to see if the specified hosted service name is available or if it has already been taken.
def check_hosted_service_name_availability(self, service_name): ''' Checks to see if the specified hosted service name is available, or if it has already been taken. service_name: Name of the hosted service. ''' _validate_not_none('service_name', service_name...
Lists all of the service certificates associated with the specified hosted service.
def list_service_certificates(self, service_name): ''' Lists all of the service certificates associated with the specified hosted service. service_name: Name of the hosted service. ''' _validate_not_none('service_name', service_name) return self._perf...
Returns the public data for the specified X. 509 certificate associated with a hosted service.
def get_service_certificate(self, service_name, thumbalgorithm, thumbprint): ''' Returns the public data for the specified X.509 certificate associated with a hosted service. service_name: Name of the hosted service. thumbalgorithm: The algorithm for the ...
Adds a certificate to a hosted service.
def add_service_certificate(self, service_name, data, certificate_format, password=None): ''' Adds a certificate to a hosted service. service_name: Name of the hosted service. data: The base-64 encoded form of the pfx/cer file. ...
Deletes a service certificate from the certificate store of a hosted service.
def delete_service_certificate(self, service_name, thumbalgorithm, thumbprint): ''' Deletes a service certificate from the certificate store of a hosted service. service_name: Name of the hosted service. thumbalgorithm: ...
The Get Management Certificate operation retrieves information about the management certificate with the specified thumbprint. Management certificates which are also known as subscription certificates authenticate clients attempting to connect to resources associated with your Windows Azure subscription.
def get_management_certificate(self, thumbprint): ''' The Get Management Certificate operation retrieves information about the management certificate with the specified thumbprint. Management certificates, which are also known as subscription certificates, authenticate clients at...
The Add Management Certificate operation adds a certificate to the list of management certificates. Management certificates which are also known as subscription certificates authenticate clients attempting to connect to resources associated with your Windows Azure subscription.
def add_management_certificate(self, public_key, thumbprint, data): ''' The Add Management Certificate operation adds a certificate to the list of management certificates. Management certificates, which are also known as subscription certificates, authenticate clients attempting ...
The Delete Management Certificate operation deletes a certificate from the list of management certificates. Management certificates which are also known as subscription certificates authenticate clients attempting to connect to resources associated with your Windows Azure subscription.
def delete_management_certificate(self, thumbprint): ''' The Delete Management Certificate operation deletes a certificate from the list of management certificates. Management certificates, which are also known as subscription certificates, authenticate clients attempting to conn...
Returns the system properties associated with the specified affinity group.
def get_affinity_group_properties(self, affinity_group_name): ''' Returns the system properties associated with the specified affinity group. affinity_group_name: The name of the affinity group. ''' _validate_not_none('affinity_group_name', affinity_group_nam...
Creates a new affinity group for the specified subscription.
def create_affinity_group(self, name, label, location, description=None): ''' Creates a new affinity group for the specified subscription. name: A name for the affinity group that is unique to the subscription. label: A name for the affinity group. The name can b...
Updates the label and/ or the description for an affinity group for the specified subscription.
def update_affinity_group(self, affinity_group_name, label, description=None): ''' Updates the label and/or the description for an affinity group for the specified subscription. affinity_group_name: The name of the affinity group. label:...
Deletes an affinity group in the specified subscription.
def delete_affinity_group(self, affinity_group_name): ''' Deletes an affinity group in the specified subscription. affinity_group_name: The name of the affinity group. ''' _validate_not_none('affinity_group_name', affinity_group_name) return self._perform_del...
List subscription operations.
def list_subscription_operations(self, start_time=None, end_time=None, object_id_filter=None, operation_result_filter=None, continuation_token=None): ''' List subscription operations. start_time: Required. An ISO8601 date. end_time: Required. An ISO8...
Reserves an IPv4 address for the specified subscription.
def create_reserved_ip_address(self, name, label=None, location=None): ''' Reserves an IPv4 address for the specified subscription. name: Required. Specifies the name for the reserved IP address. label: Optional. Specifies a label for the reserved IP address. The...
Deletes a reserved IP address from the specified subscription.
def delete_reserved_ip_address(self, name): ''' Deletes a reserved IP address from the specified subscription. name: Required. Name of the reserved IP address. ''' _validate_not_none('name', name) return self._perform_delete(self._get_reserved_ip_path(name), ...
Associate an existing reservedIP to a deployment.
def associate_reserved_ip_address( self, name, service_name, deployment_name, virtual_ip_name=None ): ''' Associate an existing reservedIP to a deployment. name: Required. Name of the reserved IP address. service_name: Required. Name of the hosted se...
Disassociate an existing reservedIP from the given deployment.
def disassociate_reserved_ip_address( self, name, service_name, deployment_name, virtual_ip_name=None ): ''' Disassociate an existing reservedIP from the given deployment. name: Required. Name of the reserved IP address. service_name: Required. Name ...
Retrieves information about the specified reserved IP address.
def get_reserved_ip_address(self, name): ''' Retrieves information about the specified reserved IP address. name: Required. Name of the reserved IP address. ''' _validate_not_none('name', name) return self._perform_get(self._get_reserved_ip_path(name), Reserv...
Retrieves the specified virtual machine.
def get_role(self, service_name, deployment_name, role_name): ''' Retrieves the specified virtual machine. service_name: The name of the service. deployment_name: The name of the deployment. role_name: The name of the role. ''' ...
Provisions a virtual machine based on the supplied configuration.
def create_virtual_machine_deployment(self, service_name, deployment_name, deployment_slot, label, role_name, system_config, os_virtual_hard_disk, network_config=None, ...
Adds a virtual machine to an existing deployment.
def add_role(self, service_name, deployment_name, role_name, system_config, os_virtual_hard_disk, network_config=None, availability_set_name=None, data_virtual_hard_disks=None, role_size=None, role_type='PersistentVMRole', resource_extension_references...
Updates the specified virtual machine.
def update_role(self, service_name, deployment_name, role_name, os_virtual_hard_disk=None, network_config=None, availability_set_name=None, data_virtual_hard_disks=None, role_size=None, role_type='PersistentVMRole', resource_extension_refer...
Deletes the specified virtual machine.
def delete_role(self, service_name, deployment_name, role_name, complete = False): ''' Deletes the specified virtual machine. service_name: The name of the service. deployment_name: The name of the deployment. role_name: The name of the role. ...
The Capture Role operation captures a virtual machine image to your image gallery. From the captured image you can create additional customized virtual machines.
def capture_role(self, service_name, deployment_name, role_name, post_capture_action, target_image_name, target_image_label, provisioning_configuration=None): ''' The Capture Role operation captures a virtual machine image to your image gallery. From the...
Starts the specified virtual machine.
def start_role(self, service_name, deployment_name, role_name): ''' Starts the specified virtual machine. service_name: The name of the service. deployment_name: The name of the deployment. role_name: The name of the role. ''' ...
Starts the specified virtual machines.
def start_roles(self, service_name, deployment_name, role_names): ''' Starts the specified virtual machines. service_name: The name of the service. deployment_name: The name of the deployment. role_names: The names of the roles, as an enumerab...
Restarts the specified virtual machine.
def restart_role(self, service_name, deployment_name, role_name): ''' Restarts the specified virtual machine. service_name: The name of the service. deployment_name: The name of the deployment. role_name: The name of the role. ''' ...
Shuts down the specified virtual machine.
def shutdown_role(self, service_name, deployment_name, role_name, post_shutdown_action='Stopped'): ''' Shuts down the specified virtual machine. service_name: The name of the service. deployment_name: The name of the deployment. role...
Shuts down the specified virtual machines.
def shutdown_roles(self, service_name, deployment_name, role_names, post_shutdown_action='Stopped'): ''' Shuts down the specified virtual machines. service_name: The name of the service. deployment_name: The name of the deployment. ...
Adds a DNS server definition to an existing deployment.
def add_dns_server(self, service_name, deployment_name, dns_server_name, address): ''' Adds a DNS server definition to an existing deployment. service_name: The name of the service. deployment_name: The name of the deployment. dns_server_name: ...
Updates the ip address of a DNS server.
def update_dns_server(self, service_name, deployment_name, dns_server_name, address): ''' Updates the ip address of a DNS server. service_name: The name of the service. deployment_name: The name of the deployment. dns_server_name: Specifies th...
Deletes a DNS server from a deployment.
def delete_dns_server(self, service_name, deployment_name, dns_server_name): ''' Deletes a DNS server from a deployment. service_name: The name of the service. deployment_name: The name of the deployment. dns_server_name: Name of the DNS serve...
Lists the versions of a resource extension that are available to add to a Virtual Machine.
def list_resource_extension_versions(self, publisher_name, extension_name): ''' Lists the versions of a resource extension that are available to add to a Virtual Machine. publisher_name: Name of the resource extension publisher. extension_name: Name of th...
Replicate a VM image to multiple target locations. This operation is only for publishers. You have to be registered as image publisher with Microsoft Azure to be able to call this.
def replicate_vm_image(self, vm_image_name, regions, offer, sku, version): ''' Replicate a VM image to multiple target locations. This operation is only for publishers. You have to be registered as image publisher with Microsoft Azure to be able to call this. vm_image_name: ...
Unreplicate a VM image from all regions This operation is only for publishers. You have to be registered as image publisher with Microsoft Azure to be able to call this
def unreplicate_vm_image(self, vm_image_name): ''' Unreplicate a VM image from all regions This operation is only for publishers. You have to be registered as image publisher with Microsoft Azure to be able to call this vm_image_name: Specifies the name of the VM Ima...
Share an already replicated OS image. This operation is only for publishers. You have to be registered as image publisher with Windows Azure to be able to call this.
def share_vm_image(self, vm_image_name, permission): ''' Share an already replicated OS image. This operation is only for publishers. You have to be registered as image publisher with Windows Azure to be able to call this. vm_image_name: The name of the virtual machi...
Creates a copy of the operating system virtual hard disk ( VHD ) and all of the data VHDs that are associated with the Virtual Machine saves the VHD copies in the same storage location as the original VHDs and registers the copies as a VM Image in the image repository that is associated with the specified subscription.
def capture_vm_image(self, service_name, deployment_name, role_name, options): ''' Creates a copy of the operating system virtual hard disk (VHD) and all of the data VHDs that are associated with the Virtual Machine, saves the VHD copies in the same storage location as the original VHDs,...
Creates a VM Image in the image repository that is associated with the specified subscription using a specified set of virtual hard disks.
def create_vm_image(self, vm_image): ''' Creates a VM Image in the image repository that is associated with the specified subscription using a specified set of virtual hard disks. vm_image: An instance of VMImage class. vm_image.name: Required. Specifies the name of ...
Deletes the specified VM Image from the image repository that is associated with the specified subscription.
def delete_vm_image(self, vm_image_name, delete_vhd=False): ''' Deletes the specified VM Image from the image repository that is associated with the specified subscription. vm_image_name: The name of the image. delete_vhd: Deletes the underlying vhd blob ...
Retrieves a list of the VM Images from the image repository that is associated with the specified subscription.
def list_vm_images(self, location=None, publisher=None, category=None): ''' Retrieves a list of the VM Images from the image repository that is associated with the specified subscription. ''' path = self._get_vm_image_path() query = '' if location: que...
Updates a VM Image in the image repository that is associated with the specified subscription.
def update_vm_image(self, vm_image_name, vm_image): ''' Updates a VM Image in the image repository that is associated with the specified subscription. vm_image_name: Name of image to update. vm_image: An instance of VMImage class. vm_image.label: ...
Adds an OS image that is currently stored in a storage account in your subscription to the image repository.
def add_os_image(self, label, media_link, name, os): ''' Adds an OS image that is currently stored in a storage account in your subscription to the image repository. label: Specifies the friendly name of the image. media_link: Specifies the location of th...
Updates an OS image that in your image repository.
def update_os_image(self, image_name, label, media_link, name, os): ''' Updates an OS image that in your image repository. image_name: The name of the image to update. label: Specifies the friendly name of the image to be updated. You cannot use this ...
Updates metadata elements from a given OS image reference.
def update_os_image_from_image_reference(self, image_name, os_image): ''' Updates metadata elements from a given OS image reference. image_name: The name of the image to update. os_image: An instance of OSImage class. os_image.label: Optional. Specifies a...