Use DATASOURCE::EDAS::Clusters to query clusters.
Syntax
{
"Type": "DATASOURCE::EDAS::Clusters",
"Properties": {
"LogicalRegionId": String,
"ResourceGroupId": String,
"RefreshOptions": String
}
}Properties
Property name | Type | Required | Update allowed | Description | Constraints |
LogicalRegionId | String | No | Yes | The ID of the namespace. | For more information about how to obtain the namespace ID, see Query a list of custom namespaces. Obtain the namespace:
|
ResourceGroupId | String | No | Yes | The ID of the resource group. | For more information about how to obtain the resource group ID, see Query resource group information. Obtain the resource group ID:
|
RefreshOptions | String | No | Yes | The refresh policy for the data source resource when the stack is updated. | Valid values:
|
Return values (Fn::GetAtt)
ClusterIds: A list of cluster IDs.
Clusters: A list of cluster details.
Property name | Type | Description | Constraints |
ClusterIds | List | A list of cluster IDs in EDAS. | None |
Clusters | List | A list of cluster details in EDAS. | None |
ClusterId | String | The ID of the cluster in EDAS. | None |
ClusterName | String | The name of the cluster. | None |
OversoldFactor | Number | The CPU oversold ratio supported by the Docker cluster. | None |
NodeNum | Number | The number of instances. | None |
ResourceGroupId | String | The ID of the resource group. | None |
ClusterType | Number | The type of the cluster. | Valid values:
|
CsClusterId | String | The ID of the Kubernetes cluster created in Container Service for Kubernetes. | None |
VpcId | String | The ID of the VPC. | None |
RegionId | String | The ID of the region. | None |
IaasProvider | String | The provider of the cluster. | None |
Cpu | String | The total number of CPU cores. | None |
CpuUsed | Number | The number of used CPU cores. | None |
Mem | Number | The total memory. | Unit: MB. |
MemUsed | Number | The used memory. | Unit: MB. |
CreateTime | Number | The timestamp when the cluster was created. | Unit: milliseconds. |
UpdateTime | Number | The timestamp of the last change to the cluster. | Unit: milliseconds. |
Examples
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
LogicalRegionId:
Type: String
Description: The ID of the namespace.
Resources:
Clusters:
Type: DATASOURCE::EDAS::Clusters
Properties:
LogicalRegionId:
Ref: LogicalRegionId
Outputs:
Clusters:
Description: The list of clusters.
Value:
Fn::GetAtt:
- Clusters
- Clusters
ClusterIds:
Description: The list of cluster IDs.
Value:
Fn::GetAtt:
- Clusters
- ClusterIds
JSON format
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"LogicalRegionId": {
"Type": "String",
"Description": "The ID of the namespace."
}
},
"Resources": {
"Clusters": {
"Type": "DATASOURCE::EDAS::Clusters",
"Properties": {
"LogicalRegionId": {
"Ref": "LogicalRegionId"
}
}
}
},
"Outputs": {
"Clusters": {
"Description": "The list of clusters.",
"Value": {
"Fn::GetAtt": [
"Clusters",
"Clusters"
]
}
},
"ClusterIds": {
"Description": "The list of cluster IDs.",
"Value": {
"Fn::GetAtt": [
"Clusters",
"ClusterIds"
]
}
}
}
}