Skip to content

Commit

Permalink
Added Start and Stop operation, plus PowerState to swagger spec (#10555)
Browse files Browse the repository at this point in the history
  • Loading branch information
NickKeller authored Aug 28, 2020
1 parent 78475b5 commit 914a3bf
Show file tree
Hide file tree
Showing 3 changed files with 139 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"parameters": {
"api-version": "2020-09-01",
"subscriptionId": "subid1",
"resourceGroupName": "rg1",
"resourceName": "clustername1"
},
"responses": {
"202": {},
"204": {}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"parameters": {
"api-version": "2020-09-01",
"subscriptionId": "subid1",
"resourceGroupName": "rg1",
"resourceName": "clustername1"
},
"responses": {
"202": {},
"204": {}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -1031,6 +1031,94 @@
}
}
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/stop": {
"post": {
"tags": [
"ManagedClusters"
],
"operationId": "ManagedClusters_Stop",
"summary": "Stop Managed Cluster",
"description": "Stops a Running Managed Cluster",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ResourceGroupNameParameter"
},
{
"$ref": "#/parameters/ResourceNameParameter"
}
],
"responses": {
"202": {
"description": "Accepted"
},
"204": {
"description": "NoContent"
},
"default": {
"description": "Error response describing why the operation failed. If the cluster doesn't exist, 404 (Not found) is returned.",
"schema": {
"$ref": "#/definitions/CloudError"
}
}
},
"x-ms-long-running-operation": true,
"x-ms-examples": {
"Stop Managed Cluster": {
"$ref": "./examples/ManagedClustersStop.json"
}
}
}
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/start": {
"post": {
"tags": [
"ManagedClusters"
],
"operationId": "ManagedClusters_Start",
"summary": "Start Managed Cluster",
"description": "Starts a Stopped Managed Cluster",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ResourceGroupNameParameter"
},
{
"$ref": "#/parameters/ResourceNameParameter"
}
],
"responses": {
"202": {
"description": "Accepted"
},
"204": {
"description": "NoContent"
},
"default": {
"description": "Error response describing why the operation failed. If the cluster doesn't exist, 404 (Not found) is returned.",
"schema": {
"$ref": "#/definitions/CloudError"
}
}
},
"x-ms-long-running-operation": true,
"x-ms-examples": {
"Start Managed Cluster": {
"$ref": "./examples/ManagedClustersStart.json"
}
}
}
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/privateEndpointConnections": {
"get": {
"tags": [
Expand Down Expand Up @@ -1860,6 +1948,11 @@
"type": "string",
"description": "The current deployment or provisioning state, which only appears in the response."
},
"powerState": {
"readOnly": true,
"description": "Describes whether the Agent Pool is Running or Stopped",
"$ref": "#/definitions/PowerState"
},
"availabilityZones": {
"type": "array",
"items": {
Expand Down Expand Up @@ -2322,6 +2415,11 @@
"type": "string",
"description": "The current deployment or provisioning state, which only appears in the response."
},
"powerState": {
"$ref": "#/definitions/PowerState",
"description": "Represents the Power State of the cluster",
"readOnly": true
},
"maxAgentPools": {
"readOnly": true,
"type": "integer",
Expand Down Expand Up @@ -2476,6 +2574,23 @@
},
"description": "Properties of the managed cluster."
},
"PowerState": {
"description": "Describes the Power State of the cluster",
"properties": {
"code": {
"type": "string",
"description": "Tells whether the cluster is Running or Stopped",
"enum": [
"Running",
"Stopped"
],
"x-ms-enum": {
"name": "code",
"modelAsString": true
}
}
}
},
"ManagedClusterAPIServerAccessProfile": {
"properties": {
"authorizedIPRanges": {
Expand Down

0 comments on commit 914a3bf

Please sign in to comment.