Skip to main content

connected_clusters

Creates, updates, deletes, gets or lists a connected_clusters resource.

Overview

Nameconnected_clusters
TypeResource
Idazure.hybrid_kubernetes.connected_clusters

Fields

The following fields are returned by SELECT queries:

Resource retrieved successfully.

NameDatatypeDescription
identityobjectThe identity of the connected cluster.
kindstringThe kind of connected cluster.
locationstringThe geo-location where the resource lives
propertiesobjectDescribes the connected cluster resource properties.
systemDataobjectMetadata pertaining to creation and last modification of the resource
tagsobjectResource tags.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectsubscriptionId, resourceGroupName, clusterNameReturns the properties of the specified connected cluster, including name, identity, properties, and additional cluster details.
list_by_resource_groupselectsubscriptionId, resourceGroupNameAPI to enumerate registered connected K8s clusters under a Resource Group
list_by_subscriptionselectsubscriptionIdAPI to enumerate registered connected K8s clusters under a Subscription
create_or_updateinsertsubscriptionId, resourceGroupName, clusterName, data__properties, data__identityAPI to register a new Kubernetes cluster and create a tracked resource in Azure Resource Manager (ARM).
updateupdatesubscriptionId, resourceGroupName, clusterNameAPI to update certain properties of the connected cluster resource
deletedeletesubscriptionId, resourceGroupName, clusterNameDelete a connected cluster, removing the tracked resource in Azure Resource Manager (ARM).

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.

NameDatatypeDescription
clusterNamestringThe name of the Kubernetes cluster on which get is called.
resourceGroupNamestringThe name of the resource group. The name is case insensitive.
subscriptionIdstringThe ID of the target subscription.

SELECT examples

Returns the properties of the specified connected cluster, including name, identity, properties, and additional cluster details.

SELECT
identity,
kind,
location,
properties,
systemData,
tags
FROM azure.hybrid_kubernetes.connected_clusters
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND clusterName = '{{ clusterName }}' -- required
;

INSERT examples

API to register a new Kubernetes cluster and create a tracked resource in Azure Resource Manager (ARM).

INSERT INTO azure.hybrid_kubernetes.connected_clusters (
data__identity,
data__kind,
data__properties,
data__tags,
data__location,
subscriptionId,
resourceGroupName,
clusterName
)
SELECT
'{{ identity }}' /* required */,
'{{ kind }}',
'{{ properties }}' /* required */,
'{{ tags }}',
'{{ location }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ clusterName }}'
RETURNING
identity,
kind,
location,
properties,
systemData,
tags
;

UPDATE examples

API to update certain properties of the connected cluster resource

UPDATE azure.hybrid_kubernetes.connected_clusters
SET
data__tags = '{{ tags }}',
data__properties = '{{ properties }}'
WHERE
subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND clusterName = '{{ clusterName }}' --required
RETURNING
identity,
kind,
location,
properties,
systemData,
tags;

DELETE examples

Delete a connected cluster, removing the tracked resource in Azure Resource Manager (ARM).

DELETE FROM azure.hybrid_kubernetes.connected_clusters
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND clusterName = '{{ clusterName }}' --required
;