volumes
Creates, updates, deletes, gets or lists a volumes
resource.
Overview
Name | volumes |
Type | Resource |
Id | azure.container_storage.volumes |
Fields
- vw_volumes
- volumes
Name | Datatype | Description |
---|---|---|
capacity_gib | text | field from the properties object |
labels | text | field from the properties object |
poolName | text | field from the properties object |
provisioning_state | text | field from the properties object |
resourceGroupName | text | field from the properties object |
status | text | field from the properties object |
subscriptionId | text | field from the properties object |
volumeName | text | field from the properties object |
volume_type | text | field from the properties object |
Name | Datatype | Description |
---|---|---|
properties | object | Volume Properties |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | poolName, resourceGroupName, subscriptionId, volumeName | Get a Volume |
list_by_pool | SELECT | poolName, resourceGroupName, subscriptionId | List Volume resources by Pool |
create_or_update | INSERT | poolName, resourceGroupName, subscriptionId, volumeName | Create a Volume |
delete | DELETE | poolName, resourceGroupName, subscriptionId, volumeName | Delete a Volume |
update | UPDATE | poolName, resourceGroupName, subscriptionId, volumeName | Update a Volume |
SELECT
examples
List Volume resources by Pool
- vw_volumes
- volumes
SELECT
capacity_gib,
labels,
poolName,
provisioning_state,
resourceGroupName,
status,
subscriptionId,
volumeName,
volume_type
FROM azure.container_storage.vw_volumes
WHERE poolName = '{{ poolName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
SELECT
properties
FROM azure.container_storage.volumes
WHERE poolName = '{{ poolName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new volumes
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.container_storage.volumes (
poolName,
resourceGroupName,
subscriptionId,
volumeName,
properties
)
SELECT
'{{ poolName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ volumeName }}',
'{{ properties }}'
;
- name: your_resource_model_name
props:
- name: properties
value:
- name: provisioningState
value: []
- name: status
value:
- name: state
value: []
- name: message
value: string
- name: labels
value: object
- name: capacityGiB
value: integer
- name: volumeType
value:
- name: elasticSan
value:
- name: targetIqn
value: string
- name: targetPortalHostname
value: string
- name: targetPortalPort
value: integer
UPDATE
example
Updates a volumes
resource.
/*+ update */
UPDATE azure.container_storage.volumes
SET
properties = '{{ properties }}'
WHERE
poolName = '{{ poolName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND volumeName = '{{ volumeName }}';
DELETE
example
Deletes the specified volumes
resource.
/*+ delete */
DELETE FROM azure.container_storage.volumes
WHERE poolName = '{{ poolName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND volumeName = '{{ volumeName }}';