targets
Creates, updates, deletes, gets or lists a targets resource.
Overview
| Name | targets |
| Type | Resource |
| Id | azure.workload_orchestration.targets |
Fields
The following fields are returned by SELECT queries:
- get
- list_by_resource_group
- list_by_subscription
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
capabilities | array | List of capabilities. Required. |
contextId | string | ArmId of Context. Required. |
description | string | Description of target. Required. |
displayName | string | Display name of target. Required. |
eTag | string | If eTag is provided in the response body, it may also be provided as a header per the normal etag convention. Entity tags are used for comparing two or more entities from the same requested resource. HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range (section 14.27) header fields. |
extendedLocation | object | :vartype extended_location: ~azure.mgmt.workloadorchestration.models.ExtendedLocation |
hierarchyLevel | string | Hierarchy Level. Required. |
location | string | The geo-location where the resource lives. Required. |
provisioningState | string | Provisioning state of resource. Known values are: "Succeeded", "Failed", "Canceled", "Initialized", "InProgress", and "Deleting". (Succeeded, Failed, Canceled, Initialized, InProgress, Deleting) |
solutionScope | string | Scope of the target resource. |
state | string | State of resource. Known values are: "active" and "inactive". (active, inactive) |
status | object | Status of target. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
targetSpecification | object | target spec. Required. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
capabilities | array | List of capabilities. Required. |
contextId | string | ArmId of Context. Required. |
description | string | Description of target. Required. |
displayName | string | Display name of target. Required. |
eTag | string | If eTag is provided in the response body, it may also be provided as a header per the normal etag convention. Entity tags are used for comparing two or more entities from the same requested resource. HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range (section 14.27) header fields. |
extendedLocation | object | :vartype extended_location: ~azure.mgmt.workloadorchestration.models.ExtendedLocation |
hierarchyLevel | string | Hierarchy Level. Required. |
location | string | The geo-location where the resource lives. Required. |
provisioningState | string | Provisioning state of resource. Known values are: "Succeeded", "Failed", "Canceled", "Initialized", "InProgress", and "Deleting". (Succeeded, Failed, Canceled, Initialized, InProgress, Deleting) |
solutionScope | string | Scope of the target resource. |
state | string | State of resource. Known values are: "active" and "inactive". (active, inactive) |
status | object | Status of target. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
targetSpecification | object | target spec. Required. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
capabilities | array | List of capabilities. Required. |
contextId | string | ArmId of Context. Required. |
description | string | Description of target. Required. |
displayName | string | Display name of target. Required. |
eTag | string | If eTag is provided in the response body, it may also be provided as a header per the normal etag convention. Entity tags are used for comparing two or more entities from the same requested resource. HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range (section 14.27) header fields. |
extendedLocation | object | :vartype extended_location: ~azure.mgmt.workloadorchestration.models.ExtendedLocation |
hierarchyLevel | string | Hierarchy Level. Required. |
location | string | The geo-location where the resource lives. Required. |
provisioningState | string | Provisioning state of resource. Known values are: "Succeeded", "Failed", "Canceled", "Initialized", "InProgress", and "Deleting". (Succeeded, Failed, Canceled, Initialized, InProgress, Deleting) |
solutionScope | string | Scope of the target resource. |
state | string | State of resource. Known values are: "active" and "inactive". (active, inactive) |
status | object | Status of target. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
targetSpecification | object | target spec. Required. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
Methods
The following methods are available for this resource:
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
subscription_id | string | |
target_name | string | Name of the target. Required. |
forceDelete | boolean | Force delete. Default value is None. |
SELECT examples
- get
- list_by_resource_group
- list_by_subscription
Get a Target Resource.
SELECT
id,
name,
capabilities,
contextId,
description,
displayName,
eTag,
extendedLocation,
hierarchyLevel,
location,
provisioningState,
solutionScope,
state,
status,
systemData,
tags,
targetSpecification,
type
FROM azure.workload_orchestration.targets
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND target_name = '{{ target_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
List by specified resource group.
SELECT
id,
name,
capabilities,
contextId,
description,
displayName,
eTag,
extendedLocation,
hierarchyLevel,
location,
provisioningState,
solutionScope,
state,
status,
systemData,
tags,
targetSpecification,
type
FROM azure.workload_orchestration.targets
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
List by subscription.
SELECT
id,
name,
capabilities,
contextId,
description,
displayName,
eTag,
extendedLocation,
hierarchyLevel,
location,
provisioningState,
solutionScope,
state,
status,
systemData,
tags,
targetSpecification,
type
FROM azure.workload_orchestration.targets
WHERE subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create_or_update
- Manifest
Create or update a Target Resource.
INSERT INTO azure.workload_orchestration.targets (
tags,
location,
properties,
extendedLocation,
resource_group_name,
target_name,
subscription_id
)
SELECT
'{{ tags }}',
'{{ location }}' /* required */,
'{{ properties }}',
'{{ extendedLocation }}',
'{{ resource_group_name }}',
'{{ target_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
eTag,
extendedLocation,
location,
properties,
systemData,
tags,
type
;
# Description fields are for documentation purposes
- name: targets
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the targets resource.
- name: target_name
value: "{{ target_name }}"
description: Required parameter for the targets resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the targets resource.
- name: tags
value: "{{ tags }}"
description: |
Resource tags.
- name: location
value: "{{ location }}"
description: |
The geo-location where the resource lives. Required.
- name: properties
description: |
The resource-specific properties for this resource.
value:
description: "{{ description }}"
displayName: "{{ displayName }}"
contextId: "{{ contextId }}"
targetSpecification: "{{ targetSpecification }}"
capabilities:
- "{{ capabilities }}"
hierarchyLevel: "{{ hierarchyLevel }}"
status:
lastModified: "{{ lastModified }}"
deployed: {{ deployed }}
expectedRunningJobId: {{ expectedRunningJobId }}
runningJobId: {{ runningJobId }}
status: "{{ status }}"
statusDetails: "{{ statusDetails }}"
generation: {{ generation }}
targetStatuses:
- name: "{{ name }}"
status: "{{ status }}"
componentStatuses: "{{ componentStatuses }}"
solutionScope: "{{ solutionScope }}"
state: "{{ state }}"
provisioningState: "{{ provisioningState }}"
- name: extendedLocation
description: |
:vartype extended_location: ~azure.mgmt.workloadorchestration.models.ExtendedLocation
value:
name: "{{ name }}"
type: "{{ type }}"
UPDATE examples
- update
update a Target Resource.
UPDATE azure.workload_orchestration.targets
SET
tags = '{{ tags }}',
location = '{{ location }}',
properties = '{{ properties }}',
extendedLocation = '{{ extendedLocation }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND target_name = '{{ target_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
RETURNING
id,
name,
eTag,
extendedLocation,
location,
properties,
systemData,
tags,
type;
REPLACE examples
- create_or_update
Create or update a Target Resource.
REPLACE azure.workload_orchestration.targets
SET
tags = '{{ tags }}',
location = '{{ location }}',
properties = '{{ properties }}',
extendedLocation = '{{ extendedLocation }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND target_name = '{{ target_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
RETURNING
id,
name,
eTag,
extendedLocation,
location,
properties,
systemData,
tags,
type;
DELETE examples
- delete
Delete a Target Resource.
DELETE FROM azure.workload_orchestration.targets
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND target_name = '{{ target_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND forceDelete = '{{ forceDelete }}'
;
Lifecycle Methods
- install_solution
- uninstall_solution
- remove_revision
- resolve_configuration
- review_solution_version
- publish_solution_version
- update_external_validation_status
Post request to deploy.
EXEC azure.workload_orchestration.targets.install_solution
@resource_group_name='{{ resource_group_name }}' --required,
@target_name='{{ target_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"solutionVersionId": "{{ solutionVersionId }}"
}'
;
Post request to uninstall.
EXEC azure.workload_orchestration.targets.uninstall_solution
@resource_group_name='{{ resource_group_name }}' --required,
@target_name='{{ target_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"solutionTemplateId": "{{ solutionTemplateId }}",
"solutionInstanceName": "{{ solutionInstanceName }}"
}'
;
Post request to remove solution version revision.
EXEC azure.workload_orchestration.targets.remove_revision
@resource_group_name='{{ resource_group_name }}' --required,
@target_name='{{ target_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"solutionTemplateId": "{{ solutionTemplateId }}",
"solutionVersion": "{{ solutionVersion }}"
}'
;
Post request to resolve configuration.
EXEC azure.workload_orchestration.targets.resolve_configuration
@resource_group_name='{{ resource_group_name }}' --required,
@target_name='{{ target_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"solutionTemplateVersionId": "{{ solutionTemplateVersionId }}",
"solutionInstanceName": "{{ solutionInstanceName }}",
"solutionDependencies": "{{ solutionDependencies }}"
}'
;
Post request to review configuration.
EXEC azure.workload_orchestration.targets.review_solution_version
@resource_group_name='{{ resource_group_name }}' --required,
@target_name='{{ target_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"solutionTemplateVersionId": "{{ solutionTemplateVersionId }}",
"solutionInstanceName": "{{ solutionInstanceName }}",
"solutionDependencies": "{{ solutionDependencies }}"
}'
;
Post request to publish.
EXEC azure.workload_orchestration.targets.publish_solution_version
@resource_group_name='{{ resource_group_name }}' --required,
@target_name='{{ target_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"solutionVersionId": "{{ solutionVersionId }}"
}'
;
Post request to update external validation status.
EXEC azure.workload_orchestration.targets.update_external_validation_status
@resource_group_name='{{ resource_group_name }}' --required,
@target_name='{{ target_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"solutionVersionId": "{{ solutionVersionId }}",
"errorDetails": "{{ errorDetails }}",
"externalValidationId": "{{ externalValidationId }}",
"validationStatus": "{{ validationStatus }}"
}'
;