The Azure cloud module is used to control access to Microsoft Azure
depends: |
|
---|---|
configuration: | Required provider parameters:
A Management Certificate (.pem and .crt files) must be created and the .pem file placed on the same machine that salt-cloud is run from. Information on creating the pem file to use, and uploading the associated cer file can be found at: http://www.windowsazure.com/en-us/develop/python/how-to-guides/service-management/ For users with Python < 2.7.9, requests_lib must currently be set to True. |
Example /etc/salt/cloud.providers
or
/etc/salt/cloud.providers.d/azure.conf
configuration:
my-azure-config:
provider: azure
subscription_id: 3287abc8-f98a-c678-3bde-326766fd3617
certificate_path: /etc/salt/azure.pem
management_host: management.core.windows.net
salt.cloud.clouds.msazure.
add_input_endpoint
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Add an input endpoint to the deployment. Please note that there may be a delay before the changes show up.
CLI Example:
salt-cloud -f add_input_endpoint my-azure service=myservice deployment=mydeployment role=myrole name=HTTP local_port=80 port=80 protocol=tcp enable_direct_server_return=False timeout_for_tcp_idle_connection=4
salt.cloud.clouds.msazure.
add_management_certificate
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Add a new management certificate
CLI Example:
salt-cloud -f add_management_certificate my-azure public_key='...PUBKEY...' thumbprint=0123456789ABCDEF data='...CERT_DATA...'
salt.cloud.clouds.msazure.
add_service_certificate
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Add a new service certificate
CLI Example:
salt-cloud -f add_service_certificate my-azure name=my_service_certificate data='...CERT_DATA...' certificate_format=sha1 password=verybadpass
salt.cloud.clouds.msazure.
avail_images
(conn=None, call=None)¶List available images for Azure
salt.cloud.clouds.msazure.
avail_locations
(conn=None, call=None)¶List available locations for Azure
salt.cloud.clouds.msazure.
avail_sizes
(call=None)¶Return a list of sizes from Azure
salt.cloud.clouds.msazure.
cleanup_unattached_disks
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Cleans up all disks associated with the account, which are not attached. * CAUTION * This is a destructive function with no undo button, and no "Are you sure?" confirmation!
CLI Examples:
salt-cloud -f cleanup_unattached_disks my-azure name=my_disk
salt-cloud -f cleanup_unattached_disks my-azure name=my_disk delete_vhd=True
salt.cloud.clouds.msazure.
create
(vm_)¶Create a single VM from a data dict
salt.cloud.clouds.msazure.
create_affinity_group
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Create a new affinity group
CLI Example:
salt-cloud -f create_affinity_group my-azure name=my_affinity_group
salt.cloud.clouds.msazure.
create_attach_volumes
(name, kwargs, call=None, wait_to_finish=True)¶Create and attach volumes to created node
salt.cloud.clouds.msazure.
create_service
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Create a new hosted service
CLI Example:
salt-cloud -f create_service my-azure name=my_service label=my_service location='West US'
salt.cloud.clouds.msazure.
create_storage
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Create a new storage account
CLI Example:
salt-cloud -f create_storage my-azure name=my_storage label=my_storage location='West US'
salt.cloud.clouds.msazure.
create_storage_container
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Create a storage container
CLI Example:
salt-cloud -f create_storage_container my-azure name=mycontainer
salt.cloud.clouds.msazure.
delete_affinity_group
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Delete a specific affinity group associated with the account
CLI Examples:
salt-cloud -f delete_affinity_group my-azure name=my_affinity_group
salt.cloud.clouds.msazure.
delete_disk
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Delete a specific disk associated with the account
CLI Examples:
salt-cloud -f delete_disk my-azure name=my_disk
salt-cloud -f delete_disk my-azure name=my_disk delete_vhd=True
salt.cloud.clouds.msazure.
delete_input_endpoint
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Delete an input endpoint from the deployment. Please note that there may be a delay before the changes show up.
CLI Example:
salt-cloud -f delete_input_endpoint my-azure service=myservice deployment=mydeployment role=myrole name=HTTP
salt.cloud.clouds.msazure.
delete_management_certificate
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Delete a specific certificate associated with the management
CLI Examples:
salt-cloud -f delete_management_certificate my-azure name=my_management_certificate thumbalgorithm=sha1 thumbprint=0123456789ABCDEF
salt.cloud.clouds.msazure.
delete_service
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Delete a specific service associated with the account
CLI Examples:
salt-cloud -f delete_service my-azure name=my_service
salt.cloud.clouds.msazure.
delete_service_certificate
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Delete a specific certificate associated with the service
CLI Examples:
salt-cloud -f delete_service_certificate my-azure name=my_service_certificate thumbalgorithm=sha1 thumbprint=0123456789ABCDEF
salt.cloud.clouds.msazure.
delete_storage
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Delete a specific storage account
CLI Examples:
salt-cloud -f delete_storage my-azure name=my_storage
salt.cloud.clouds.msazure.
delete_storage_container
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Delete a container associated with the storage account
CLI Example:
salt-cloud -f delete_storage_container my-azure name=mycontainer
salt.cloud.clouds.msazure.
destroy
(name, conn=None, call=None, kwargs=None)¶Destroy a VM
CLI Examples:
salt-cloud -d myminion
salt-cloud -a destroy myminion service_name=myservice
salt.cloud.clouds.msazure.
get_affinity_group
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Show an affinity group associated with the account
CLI Example:
salt-cloud -f show_affinity_group my-azure service=myservice deployment=mydeployment name=SSH
salt.cloud.clouds.msazure.
get_blob
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Download a blob
CLI Example:
salt-cloud -f get_blob my-azure container=base name=top.sls local_path=/srv/salt/top.sls
salt-cloud -f get_blob my-azure container=base name=content.txt return_content=True
salt.cloud.clouds.msazure.
get_blob_properties
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Returns all user-defined metadata, standard HTTP properties, and system properties for the blob.
CLI Example:
salt-cloud -f show_blob_properties my-azure container=mycontainer blob=myblob
salt.cloud.clouds.msazure.
get_blob_service_properties
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Show a blob's service properties
CLI Example:
salt-cloud -f show_blob_service_properties my-azure
salt.cloud.clouds.msazure.
get_configured_provider
()¶Return the first configured instance.
salt.cloud.clouds.msazure.
get_conn
()¶Return a conn object for the passed VM data
salt.cloud.clouds.msazure.
get_deployment
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Return information about a deployment
CLI Example:
salt-cloud -f show_deployment my-azure name=my_deployment
salt.cloud.clouds.msazure.
get_disk
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Return information about a disk
CLI Example:
salt-cloud -f show_disk my-azure name=my_disk
salt.cloud.clouds.msazure.
get_input_endpoint
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Show an input endpoint associated with the deployment
CLI Example:
salt-cloud -f show_input_endpoint my-azure service=myservice deployment=mydeployment name=SSH
salt.cloud.clouds.msazure.
get_management_certificate
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Return information about a management_certificate
CLI Example:
salt-cloud -f get_management_certificate my-azure name=my_management_certificate thumbalgorithm=sha1 thumbprint=0123456789ABCDEF
salt.cloud.clouds.msazure.
get_operation_status
(kwargs=None, conn=None, call=None)¶New in version 2015.2.
Get Operation Status, based on a request ID
CLI Example:
salt-cloud -f get_operation_status my-azure id=0123456789abcdef0123456789abcdef
salt.cloud.clouds.msazure.
get_service_certificate
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Return information about a service certificate
CLI Example:
salt-cloud -f show_service_certificate my-azure name=my_service_certificate thumbalgorithm=sha1 thumbprint=0123456789ABCDEF
salt.cloud.clouds.msazure.
get_storage
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List storage service properties
CLI Example:
salt-cloud -f show_storage my-azure name=my_storage
salt.cloud.clouds.msazure.
get_storage_conn
(storage_account=None, storage_key=None, conn_kwargs=None)¶New in version Beryllium.
Return a storage_conn object for the storage account
salt.cloud.clouds.msazure.
get_storage_container
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Show a container associated with the storage account
CLI Example:
salt-cloud -f show_storage_container my-azure name=myservice
salt.cloud.clouds.msazure.
get_storage_container_acl
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Show a storage container's acl
CLI Example:
salt-cloud -f show_storage_container_acl my-azure name=myservice
salt.cloud.clouds.msazure.
get_storage_container_metadata
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Show a storage container's metadata
CLI Example:
salt-cloud -f show_storage_container_metadata my-azure name=myservice
salt.cloud.clouds.msazure.
get_storage_keys
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Show storage account keys
CLI Example:
salt-cloud -f show_storage_keys my-azure name=my_storage
salt.cloud.clouds.msazure.
lease_storage_container
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Lease a container associated with the storage account
CLI Example:
salt-cloud -f lease_storage_container my-azure name=mycontainer
salt.cloud.clouds.msazure.
list_affinity_groups
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List input endpoints associated with the deployment
CLI Example:
salt-cloud -f list_affinity_groups my-azure
salt.cloud.clouds.msazure.
list_blobs
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
List blobs associated with the container
CLI Example:
salt-cloud -f list_blobs my-azure container=mycontainer
Optional. Specifies one or more datasets to include in the response. To specify more than one of these options on the URI, you must separate each option with a comma. Valid values are:
salt.cloud.clouds.msazure.
list_disks
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List disks associated with the account
CLI Example:
salt-cloud -f list_disks my-azure
salt.cloud.clouds.msazure.
list_hosted_services
(conn=None, call=None)¶List VMs on this Azure account, with full information
salt.cloud.clouds.msazure.
list_input_endpoints
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List input endpoints associated with the deployment
CLI Example:
salt-cloud -f list_input_endpoints my-azure service=myservice deployment=mydeployment
salt.cloud.clouds.msazure.
list_management_certificates
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List management certificates associated with the subscription
CLI Example:
salt-cloud -f list_management_certificates my-azure name=my_management
salt.cloud.clouds.msazure.
list_nodes
(conn=None, call=None)¶List VMs on this Azure account
salt.cloud.clouds.msazure.
list_nodes_full
(conn=None, call=None)¶List VMs on this Azure account, with full information
salt.cloud.clouds.msazure.
list_nodes_select
(conn=None, call=None)¶Return a list of the VMs that are on the provider, with select fields
salt.cloud.clouds.msazure.
list_service_certificates
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List certificates associated with the service
CLI Example:
salt-cloud -f list_service_certificates my-azure name=my_service
salt.cloud.clouds.msazure.
list_services
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List hosted services associated with the account
CLI Example:
salt-cloud -f list_services my-azure
salt.cloud.clouds.msazure.
list_storage
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List storage accounts associated with the account
CLI Example:
salt-cloud -f list_storage my-azure
salt.cloud.clouds.msazure.
list_storage_containers
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
List containers associated with the storage account
CLI Example:
salt-cloud -f list_storage_containers my-azure
salt.cloud.clouds.msazure.
list_storage_services
(conn=None, call=None)¶List VMs on this Azure account, with full information
salt.cloud.clouds.msazure.
list_virtual_networks
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List input endpoints associated with the deployment
CLI Example:
salt-cloud -f list_virtual_networks my-azure service=myservice deployment=mydeployment
salt.cloud.clouds.msazure.
make_blob_url
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Creates the URL to access a blob
CLI Example:
salt-cloud -f make_blob_url my-azure container=mycontainer blob=myblob
salt.cloud.clouds.msazure.
put_blob
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Upload a blob
CLI Examples:
salt-cloud -f put_blob my-azure container=base name=top.sls blob_path=/srv/salt/top.sls
salt-cloud -f put_blob my-azure container=base name=content.txt blob_content='Some content'
salt.cloud.clouds.msazure.
query
(path, method='GET', data=None, params=None, header_dict=None, decode=True)¶Perform a query directly against the Azure REST API
salt.cloud.clouds.msazure.
regenerate_storage_keys
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Regenerate storage account keys. Requires a key_type ("primary" or "secondary") to be specified.
CLI Example:
salt-cloud -f regenerate_storage_keys my-azure name=my_storage key_type=primary
salt.cloud.clouds.msazure.
script
(vm_)¶Return the script deployment object
salt.cloud.clouds.msazure.
set_blob_properties
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Set a blob's properties
CLI Example:
salt-cloud -f set_blob_properties my-azure
salt.cloud.clouds.msazure.
set_blob_service_properties
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Sets the properties of a storage account's Blob service, including Windows Azure Storage Analytics. You can also use this operation to set the default request version for all incoming requests that do not have a version specified.
CLI Example:
salt-cloud -f set_blob_service_properties my-azure
salt.cloud.clouds.msazure.
set_storage_container_acl
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Set a storage container's acl
CLI Example:
salt-cloud -f set_storage_container my-azure name=mycontainer
salt.cloud.clouds.msazure.
set_storage_container_metadata
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Set a storage container's metadata
CLI Example:
salt-cloud -f set_storage_container my-azure name=mycontainer x_ms_meta_name_values='{"my_name": "my_value"}'
salt.cloud.clouds.msazure.
show_affinity_group
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Show an affinity group associated with the account
CLI Example:
salt-cloud -f show_affinity_group my-azure service=myservice deployment=mydeployment name=SSH
salt.cloud.clouds.msazure.
show_blob_properties
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Returns all user-defined metadata, standard HTTP properties, and system properties for the blob.
CLI Example:
salt-cloud -f show_blob_properties my-azure container=mycontainer blob=myblob
salt.cloud.clouds.msazure.
show_blob_service_properties
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Show a blob's service properties
CLI Example:
salt-cloud -f show_blob_service_properties my-azure
salt.cloud.clouds.msazure.
show_deployment
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Return information about a deployment
CLI Example:
salt-cloud -f show_deployment my-azure name=my_deployment
salt.cloud.clouds.msazure.
show_disk
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Return information about a disk
CLI Example:
salt-cloud -f show_disk my-azure name=my_disk
salt.cloud.clouds.msazure.
show_input_endpoint
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Show an input endpoint associated with the deployment
CLI Example:
salt-cloud -f show_input_endpoint my-azure service=myservice deployment=mydeployment name=SSH
salt.cloud.clouds.msazure.
show_instance
(name, call=None)¶Show the details from the provider concerning an instance
salt.cloud.clouds.msazure.
show_management_certificate
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Return information about a management_certificate
CLI Example:
salt-cloud -f get_management_certificate my-azure name=my_management_certificate thumbalgorithm=sha1 thumbprint=0123456789ABCDEF
salt.cloud.clouds.msazure.
show_service
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List hosted service properties
CLI Example:
salt-cloud -f show_service my-azure name=my_service
salt.cloud.clouds.msazure.
show_service_certificate
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Return information about a service certificate
CLI Example:
salt-cloud -f show_service_certificate my-azure name=my_service_certificate thumbalgorithm=sha1 thumbprint=0123456789ABCDEF
salt.cloud.clouds.msazure.
show_storage
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
List storage service properties
CLI Example:
salt-cloud -f show_storage my-azure name=my_storage
salt.cloud.clouds.msazure.
show_storage_container
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Show a container associated with the storage account
CLI Example:
salt-cloud -f show_storage_container my-azure name=myservice
salt.cloud.clouds.msazure.
show_storage_container_acl
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Show a storage container's acl
CLI Example:
salt-cloud -f show_storage_container_acl my-azure name=myservice
salt.cloud.clouds.msazure.
show_storage_container_metadata
(kwargs=None, storage_conn=None, call=None)¶New in version Beryllium.
Show a storage container's metadata
CLI Example:
salt-cloud -f show_storage_container_metadata my-azure name=myservice
salt.cloud.clouds.msazure.
show_storage_keys
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Show storage account keys
CLI Example:
salt-cloud -f show_storage_keys my-azure name=my_storage
salt.cloud.clouds.msazure.
update_affinity_group
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Update an affinity group's properties
CLI Example:
salt-cloud -f update_affinity_group my-azure name=my_group label=my_group
salt.cloud.clouds.msazure.
update_disk
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Update a disk's properties
CLI Example:
salt-cloud -f update_disk my-azure name=my_disk label=my_disk
salt-cloud -f update_disk my-azure name=my_disk new_name=another_disk
salt.cloud.clouds.msazure.
update_input_endpoint
(kwargs=None, conn=None, call=None, activity='update')¶New in version Beryllium.
Update an input endpoint associated with the deployment. Please note that there may be a delay before the changes show up.
CLI Example:
salt-cloud -f update_input_endpoint my-azure service=myservice deployment=mydeployment role=myrole name=HTTP local_port=80 port=80 protocol=tcp enable_direct_server_return=False timeout_for_tcp_idle_connection=4
salt.cloud.clouds.msazure.
update_storage
(kwargs=None, conn=None, call=None)¶New in version Beryllium.
Update a storage account's properties
CLI Example:
salt-cloud -f update_storage my-azure name=my_storage label=my_storage