Download OpenAPI specification:Download
Welcome to the Spot by Flexera OpenAPI Specification. Here you will find REST definitions for all Spot products and platform administration tasks.
The API is hosted at https://api.spotinst.io
and requires Bearer Token
Authentication.
For more information on how to use the Spot platform, including user guides, developer guides, concepts, and tutorials, see the external Spot Documentation.
Create a new user and link it to the creator's organization (the organization ID from the personal token attached to the API call). If the role is a viewer, the user is also linked to the default account for the organization.
generateToken | boolean Example: generateToken=true If |
string | |
firstName | string The first name of the user. Note: names cannot include these characters: + = @ |
lastName | string The last name of the user. Note: names cannot include these characters: + = @ |
password | string Password |
role | string User's role |
{- "firstName": "Test",
- "lastName": "Test",
- "email": "test@spot.io",
- "password": "password1234",
- "role": "viewer"
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/user/?generateToken=true",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:setup:user",
- "items": [
- {
- "id": 9056,
- "firstName": "Test",
- "lastName": "Test",
- "displayName": "Test Test",
- "email": "test@gmail.com",
- "organizationId": 606079860000,
- "personalAccessToken": "...",
- "userId": "u-1a2b3c4d"
}
], - "count": 1
}
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/organization/user",
- "method": "GET",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "userId": "u-a1b2c3d4",
- "username": "John Doe",
- "type": "personal",
- "email": "john.doe@company.com",
- "mfa": "false",
- "groupNames": [
- "Developers",
- "DevOps"
]
}, - {
- "userId": "u-4d3c2b1a",
- "userName": "Jane Doe",
- "type": "personal",
- "email": "jane.doe@company.com",
- "mfa": "true",
- "groupNames": [
- "DevOps",
- "IT"
]
}
], - "count": 2,
- "kind": "spotinst:setup:organization:user"
}
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/organization/policy",
- "method": "GET",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "pol-a1b2c3d4",
- "name": "Developers",
- "description": "A policy that contains permissions for developers",
- "type": "ORGANIZATION",
- "policyContent": {
- "statements": [
- {
- "effect": "ALLOW",
- "actions": [
- "elastigroup:createGroup",
- "elastigroup:updateGroup"
], - "resources": [
- "*"
]
}
]
}, - "createdAt": "2021-12-19T13:44:13.000+0000",
- "updatedAt": "2022-01-02T22:04:29.000+0000"
}, - {
- "id": "pol-87654321",
- "name": "DevOps",
- "description": "A policy that contains permissions for DevOps",
- "type": "ACCOUNT",
- "policyContent": {
- "statements": [
- {
- "effect": "ALLOW",
- "actions": [
- "setup:updatePolicy"
], - "resources": [
- "*"
]
}
]
}, - "createdAt": "2021-12-19T13:44:13.000+0000",
- "updatedAt": "2022-01-02T22:04:29.000+0000"
}
], - "count": 2,
- "kind": "spotinst:setup:organization:policy"
}
}
Get all the details of a given user.
userId required | string Example: u-1234abcd Identifier of a user. |
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/user/u-1234abcd",
- "method": "GET",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": {
- "0": { },
- "userId": "u-a1b2c3d4",
- "username": "John Doe",
- "type": "personal",
- "email": "john.doe@company.com",
- "mfa": "false",
- "groups": [
- {
- "id": "ugr-12345678",
- "name": "DevOps",
- "policyNames": [
- "DevOps-PROD",
- "DevOps-DEV",
- "IT"
]
}, - {
- "id": "ugr-87654321",
- "name": "IT",
- "policyNames": [
- "IT"
]
}
], - "policies": [
- {
- "policyId": "pol-12345678",
- "policyName": "TriggerDeployment",
- "policyType": "ACCOUNT",
- "accountIds": [
- "act-12345678",
- "act-87654321"
]
}, - {
- "policyId": "pol-87654321",
- "policyName": "UpdateScheduling",
- "policyType": "ORGANIZATION",
- "accountIds": [ ]
}
], - "tokens": [
- {
- "name": "my_sweet_token",
- "createdAt": "2020-06-01T12:17:51.000+000",
- "tokenId": 11111,
- "tokenLastDigits": "2323"
}
]
}, - "count": 1,
- "kind": "spotinst:setup:access:user"
}
}
Delete a given user(console or programmatic) from organization.
userId required | string Example: u-1234abcd or pu-87654321 Identifier of a user. |
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/user/u-1234abcd",
- "method": "DELETE",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Update the mapping of a given user to user groups
userId required | string Example: u-1234abcd Identifier of a user. |
userGroupIds | Array of strings A list of the user groups to register the given user to (should be existing user groups only) |
{- "userGroupIds": [
- "ugr-12345678",
- "ugr-87654321"
]
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/user/u-1234abcd/userGroupMapping",
- "method": "PUT",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Update the mapping of a given user directly to policies
userId required | string Example: u-1234abcd Identifier of a user. |
Array of objects The policies to register under the given user (should be existing policies only) | |||||
Array
|
{- "policies": [
- {
- "policyId": "pol-12345678",
- "accountIds": [
- "act-12345678"
]
}, - {
- "policyId": "pol-87654321",
- "accountIds": [
- "act-12345678",
- "act-87654321"
]
}
]
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/user/u-1234abcd/policyMapping?accountId=act-567c21",
- "method": "PUT",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Get user's account mapping
userEmail required | string Example: userEmail=test@spot.io Target user email address |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/accountUserMapping?userEmail=test@spot.io",
- "method": "GET",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:aws:ec2:group:log",
- "items": [
- {
- "accountId": "act-1234592",
- "role": "editor"
}, - {
- "accountId": "act-1234593",
- "role": "viewer"
}
], - "count": 2
}
}
Delete a Spot Organization. ID of the organization can be obtained from your Spot console via the following link: https://console.spotinst.com/#/settings/organization/general > Note: This cannot be undone. Take caution.
organizationId required | string Example: 606079812345 ID of the organization you would like to delete |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/organization/606079812345",
- "method": "DELETE",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
This API creates a new programmatic user (not a human user). Use this API to provide privileges to an application that needs to interface with Spot. Spot returns a token that the programmatic user can use to perform actions with. requires accounts
or policies
.
Array of objects All the accounts the programmatic user will have access to. If used - Cannot be empty. | |
description | string Brief description of the user. |
name required | string Name of the programmatic user. Note: names cannot include these characters: + = @ |
Array of objects All the policies the programmatic user will have access to. If used - Cannot be empty. |
{- "description": "test programmatic",
- "name": "testProgrammaticApi",
- "accounts": [
- {
- "id": "act-123",
- "role": "viewer"
}
], - "policies": [
- {
- "policyId": "pol-123",
- "accountIds": [
- "act-123",
- "act-321"
]
}
]
}
{- "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:setup:programmaticUser",
- "items": [
- {
- "token": "f872e7b157866a36229d915aa21cf430f661234568703fd",
- "name": "TestApi1",
- "id": "pu-6a6976ab"
}
], - "count": 1
}
}
Create a Spot Organization.
object Organization | |||
|
{- "organization": {
- "name": "organizationName"
}
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/organization",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:setup:organization",
- "items": [
- {
- "organizationId": 12345678,
- "organizationName": "organizationName"
}
], - "count": 1
}
}
Get actions for access policies.
category | string Example: category=update The policy action category that you would like to get the information for |
name | string Example: name=ocean:updateCluster The policy action Name that you would like to get the information for |
resourcePattern | string Example: resourcePattern=ocean:o-* The policy action resource pattern that you would like to get the information for |
scope | string Example: scope=account The policy action scope that you would like to get the information for |
service | string Example: service=ocean The policy action service that you would like to get the information for |
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/access/policyAction?service=ocean&resourcePattern=ocean:ols-*&category=update",
- "method": "GET",
- "timestamp": "2022-04-14T05:05:26.044Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "name": "ocean:updateLaunchSpec",
- "service": "ocean",
- "resourcePattern": "ocean:ols-*",
- "scope": "ACCOUNT",
- "category": "UPDATE"
}, - {
- "name": "ocean:launchNodesInLaunchSpec",
- "service": "ocean",
- "resourcePattern": "ocean:ols-*",
- "scope": "ACCOUNT",
- "category": "UPDATE"
}, - {
- "name": "ocean:updateClusterLaunchSpec",
- "service": "ocean",
- "resourcePattern": "ocean:ols-*",
- "scope": "ACCOUNT",
- "category": "UPDATE"
}
], - "count": 3,
- "kind": "spotinst:setup:policyAction"
}
}
Create an access policy to define the user's permissions more granularly than the role-based permissions.
object Set access policy settings. Example - Acme, Inc. | |||||||
|
{- "policy": {
- "name": "my policy",
- "description": "description of my policy",
- "policyContent": {
- "statements": [
- {
- "effect": "ALLOW",
- "actions": [
- "ocean:importCluster"
], - "resources": [
- "*"
]
}, - {
- "effect": "ALLOW",
- "actions": [
- "emr:scale"
], - "resources": [
- "*"
]
}
]
}
}
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/access/policy?accountId=act-6sd665cs\"",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:setup:access:policy",
- "items": [
- {
- "name": "my policy",
- "description": "description of my policy",
- "policyContent": [
- { }
], - "id": "pol-de9716be"
}
], - "count": 1
}
}
Updates an access policy settings.
policyId required | string Example: pol-2344nn The access policy ID to operate on |
object Set access policy settings | |||
|
{- "policy": {
- "name": "A wonderful policy"
}
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/access/policy/pol-2344nn?accountId=act-4fbdvfc6",
- "method": "PUT",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Deletes an access policy settings.
policyId required | string Example: pol-2344nn The access policy ID to operate on |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/access/policy/pol-2344nn?accountId=act-123456789",
- "method": "DELETE",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/access/userGroup?accountId=act-567c21",
- "method": "GET",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ugr-a1b2c3d4",
- "name": "Developers",
- "description": "managing permissions to my group of developers",
- "createdAt": "2020-11-04T11:29:10.000+0000",
- "usersCount": 10,
- "policyNames": [
- "TriggerDeployment"
]
}, - {
- "id": "ugr-4d3c2b1a",
- "name": "DevOps",
- "description": "managing permissions to my group of DevOps",
- "createdAt": "2020-09-01T11:28:00.000+0000",
- "usersCount": 5,
- "policyNames": [
- "TriggerDeployment",
- "UpdateScaling",
- "UpdateScheduling"
]
}
], - "count": 2,
- "kind": "spotinst:setup:access:userGroup"
}
}
Create a new user-group of your Spot organization
description | string user group description |
name | string Name of the user group. Note: names cannot include these characters: + = @ |
Array of objects The policies to register under the given group (should be existing policies only) | |
userIds | Array of strings The users to register under the created group (should be existing users only) |
{- "name": "Developers",
- "description": "managing permissions to my group of developers",
- "userIds": [
- "u-12345678",
- "pu-12345678"
], - "policies": [
- {
- "policyId": "pol-12345678",
- "accountIds": [
- "act-12345678"
]
}, - {
- "policyId": "pol-87654321",
- "accountIds": [
- "act-12345678",
- "act-87654321"
]
}
]
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/access/userGroup?accountId=act-567c21",
- "method": "POST",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": {
- "0": { },
- "id": "ugr-a1b2c3d4",
- "name": "Developers",
- "description": "managing permissions to my group of developers",
- "createdAt": "2020-11-04T11:29:10.000+0000",
- "userIds": [
- "u-12345678",
- "pu-12345678"
], - "policies": [
- {
- "policyId": "pol-12345678",
- "accountIds": [
- "act-12345678"
]
}, - {
- "policyId": "pol-87654321",
- "accountIds": [
- "act-12345678",
- "act-87654321"
]
}
]
}, - "count": 1,
- "kind": "spotinst:setup:access:userGroup"
}
}
Get the details of a user Group
userGroupId required | string Example: ugr-1234abcd Identifier of a user Group. |
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/access/userGroup/urg-1234abcd?accountId=act-567c21",
- "method": "GET",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": {
- "0": { },
- "id": "ugr-a1b2c3d4",
- "name": "Developers",
- "description": "managing permissions to my group of developers",
- "createdAt": "2020-11-04T11:29:10.000+0000",
- "users": [
- {
- "userId": "u-12345678",
- "userName": "Clark Kent",
- "type": "personal"
}, - {
- "userId": "pu-87654321",
- "userName": "Superman",
- "type": "programmatic"
}
], - "policies": [
- {
- "policyId": "pol-12345678",
- "policyName": "TriggerDeployment",
- "policyType": "ACCOUNT",
- "accountIds": [
- "act-12345678",
- "act-87654321"
]
}, - {
- "policyId": "pol-87654321",
- "policyName": "UpdateScheduling",
- "policyType": "ORGANIZATION"
}
]
}, - "count": 1,
- "kind": "spotinst:setup:access:userGroup"
}
}
Update the details of a user Group
userGroupId required | string Example: ugr-1234abcd Identifier of a user Group. |
description | string non-empty user group description |
name | string non-empty user group name |
{- "name": "Developers",
- "description": "managing permissions to my group of developers"
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/access/userGroup/urg-1234abcd?accountId=act-567c21",
- "method": "PUT",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Delete a user Group
userGroupId required | string Example: ugr-1234abcd Identifier of a user Group. |
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/access/userGroup/urg-1234abcd?accountId=act-567c21",
- "method": "DELETE",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Update the mapping of a given user group to users
userGroupId required | string Example: ugr-1234abcd Identifier of a user Group. |
userIds | Array of strings The users to register under the given user group (should be existing users only) |
{- "userIds": [
- "u-12345678",
- "pu-12345678"
]
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/access/userGroup/urg-1234abcd/userMapping?accountId=act-567c21",
- "method": "PUT",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Update the mapping of a given user group to policies
userGroupId required | string Example: ugr-1234abcd Identifier of a user Group. |
Array of objects The policies to register under the given user group (should be existing policies only) | |||||
Array
|
{- "policies": [
- {
- "policyId": "pol-12345678",
- "accountIds": [
- "act-12345678"
]
}, - {
- "policyId": "pol-87654321",
- "accountIds": [
- "act-12345678",
- "act-87654321"
]
}
]
}
{- "request": {
- "id": "3ab3fdf7-3af3-46db-9e63-b88cfdac058c",
- "url": "/setup/access/userGroup/urg-1234abcd/policyMapping?accountId=act-567c21",
- "method": "PUT",
- "timestamp": "2018-08-20T15:31:12.730Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Get all available FinOps authorization policies.
paginationKey | string key used to fetch the next page of items |
paginationSize | integer number of items to include in the response |
targetOrganizationId | string |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cbi/v1/access/policy",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "policyId": "BE-ViewAllOnly",
- "policyName": "Billing Engine View All Only",
- "policyDescription": "Grants authorization to view all features in Billing Engine. This policy requires and will automatically grant access to all accounts within Billing Engine.",
- "requiresAccessToAllAccounts": true
}
], - "count": 1,
- "kind": "spotinst:cbi:authorization:policy",
- "paginationInfo": {
- "totalCount": 0,
- "nextKey": "string",
- "previousKey": "string"
}
}
}
Get the user-level FinOps authorization configuration for the specified user.
userId required | string The userId to retrieve. |
includeChildOrgs | boolean Default: false Include the configurations for child organizations. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cbi/v1/access/user/{userId}",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "organizationId": "11111111111111",
- "userId": "u-12345678",
- "costTypes": [
- {
- "id": "Effective",
- "name": "Effective Cost"
}
], - "accounts": [
- {
- "id": "aws~11111111111111",
- "name": "Test"
}
], - "policies": [
- {
- "id": "BE-ViewAllOnly",
- "name": "Billing Engine View All Only"
}
]
}
], - "count": 1,
- "kind": "spotinst:cbi:authorization:user"
}
}
Update the FinOps authorization configuration for a user.
userId required | string |
object (userAuthConfigChanges) The FinOps authorization changes for a user. | |||||||||||||||
|
{- "authChanges": {
- "resetCostTypes": true,
- "costTypeChanges": [
- {
- "id": "None",
- "action": "Add"
}
], - "organizationId": "string",
- "resetAccounts": true,
- "accountChanges": [
- {
- "id": "string",
- "action": "Add"
}
], - "resetPolicies": true,
- "policyChanges": [
- {
- "id": "string",
- "action": "Add"
}
]
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cbi/v1/access/user/{userId}",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "userId": "u-12345678",
- "beforeChanges": {
- "organizationId": "11111111111111",
- "userId": "u-12345678",
- "costTypes": [
- {
- "id": "Effective",
- "name": "Effective Cost"
}
], - "accounts": [
- {
- "id": "aws~11111111111111",
- "name": "Test"
}
], - "policies": [
- {
- "id": "BE-ViewAllOnly",
- "name": "Billing Engine View All Only"
}
]
}, - "afterChanges": {
- "organizationId": "11111111111111",
- "userId": "u-12345678",
- "costTypes": [
- {
- "id": "Effective",
- "name": "Effective Cost"
}
], - "accounts": [
- {
- "id": "aws~11111111111111",
- "name": "Test"
}
], - "policies": [
- {
- "id": "BE-ViewAllOnly",
- "name": "Billing Engine View All Only"
}
]
}
}
], - "count": 1,
- "kind": "spotinst:cbi:authorization:user"
}
}
Update information in an account such as the account name and slack channel. To use this command, permissions for organization admin are required. Granular permissions will require access policies with the following actions: setup:updateAccount
accountId required | string Example: act-123456789 The ID of the account you want to update. |
required | object Used for updating items in an account. | ||||
|
{- "account": {
- "slackNotificationChannels": [
], - "name": "ACCOUNT_NAME"
}
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/account/act-4fb595c6?accountId=act-4fb595c6",
- "method": "PUT",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Delete a Spot Account. The Spot Account ID can be obtained from your Spot console via the following link: https://console.spotinst.com/#/settings/account/general . Note This cannot be undone – take caution. Only Organization Admins can perform this action. In case you want to delete your default Spot account which is the account visible when you first log in please contact Support.
accountId required | string Example: act-123456789 The ID of the account you want to delete. |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/account/act-123456",
- "method": "DELETE",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Get all users in the organization, their details, and mapped accounts. Providing the optional account ID parameter will filter out all users not mapped to that account.
accountId | string Example: accountId=act-123abc ID of the account you would like to get retrieve users from |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/user?accountId=act-123456789",
- "method": "GET",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:aws:ec2:group:log",
- "items": [
- {
- "mappedAccountIds": [
- "act-0b18f123",
- "act-0b18f124",
- "act-0b18f125"
], - "userId": "u-19265",
- "displayName": "test",
- "email": "test@spot.io"
}, - {
- "mappedAccountIds": [
- "act-0b18f123",
- "act-0b18f124",
- "act-0b18f125"
], - "userId": "u-19266",
- "displayName": "test",
- "email": "abc@google.com"
}
], - "count": 2
}
}
Assign users to accounts in bulk. Only accounts under the creator's own organization are allowed. Creator's organization ID is taken from the personal token attached to the API call.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
Array of assignUsersToAccounts-example2 (object) or assignUsersToAccounts-example3 (object) Mappings objects include user, accountID and role. | |||||||
Array Any of
|
{- "mappings": [
- {
- "userId": "u-1234",
- "accountId": "act-123abc",
- "role": "editor"
}, - {
- "userId": "u-1234",
- "accountId": "act-123abc",
- "permissionStrategy": "ROLE_BASED",
- "role": "editor"
}
]
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/accountUserMapping?accountId=act-4fab9sc6",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Change the users' permissions for an account (only accounts under the creator's own organization are allowed). Creator's organization ID is taken from the personal token attached to the API call.
accountId required | string Example: act-123abc ID of the account associated with your token |
permissionStrategy | string Default: "ROLE_BASED" Set the user permissions type, by role or by access policy. Valid values "ROLE_BASED", "POLICY_BASED" |
role | string Valid values "viewer", "editor". Required on permissionStrategy = ROLE_BASED |
userId | string One of userEmail / userId is required. identify user by its user ID |
{- "userId": "u-1234",
- "permissionStrategy": "POLICY_BASED",
- "role": "editor"
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/account/act-4fb595c6/user/",
- "method": "PUT",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Detach a user from an account (only accounts under the creator's own organization are allowed). Creator's organization ID is taken from the personal token attached to the API call.
accountId required | string Example: act-123456789 The ID of the account you want to update. |
userEmail required | string Email of the user that is going to be deleted |
{- "userEmail": "test@gmail.com"
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/account/act-12345678/user/",
- "method": "DELETE",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Add a user to the account and set its permissions on the account. Creator's organization ID is taken from the personal token attached to the API call.
accountId required | string Example: act-123456789 The ID of the account you want to update. |
role | string Valid values - "viewer", "editor". Required on permissionStrategy = ROLE_BASED |
userEmail | string One of userEmail / userId is required. identify user by its user ID |
{- "userEmail": "test@spot.io",
- "role": "viewer"
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/account/act-4fb765c6/user",
- "method": "PUT",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Create a Spot account.
object Account | |||
|
{- "account": {
- "name": "AccountName"
}
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/account",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:setup:account",
- "items": [
- {
- "id": "act-123456",
- "name": "AccountName",
- "organizationId": 606012341234
}
], - "count": 1
}
}
Get a list of Spot accounts in your organization. When used without any parameters, the provided token must have Organization Admin permissions and the output will contain all the Organization's accounts. Note In case you want to list all the accounts associated with Organization you can use the below request URL without the cloudAccountId parameter, https://api.spotinst.io/setup/account
cloudAccountId | string Example: cloudAccountId=634245686616 Will list only the Spot accounts connected to the specified account ID. |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/account?cloudAccountId=123456789",
- "method": "GET",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:setup:account",
- "items": [
- {
- "accountId": "act-57765123",
- "organizationId": 606079861123,
- "name": "test",
- "providerExternalId": 123456789
}, - {
- "accountId": "act-57765123",
- "organizationId": 606079861123,
- "name": "prod",
- "providerExternalId": 123456789
}
], - "count": 2
}
}
Get access policy settings.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/access/policy?accountId=act-4fd325c3",
- "method": "GET",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:setup:access:policy",
- "items": [
- {
- "name": "my policy",
- "description": "description of my policy",
- "policyContent": {
- "statements": [
- {
- "effect": "ALLOW",
- "actions": [
- [
- "ocean:importCluster"
]
], - "resources": [
- [
- "*"
]
]
}
]
}, - "id": "pol-de9716be",
- "createdAt": "2020-01-21T12:37:14.000+0000",
- "updatedAt": "2020-01-21T12:37:14.000+0000"
}
], - "count": 1
}
}
Link a Spot account to an AWS Cloud account.
Please create external id using spot api (see /setup/credentials/aws/externalId)
and use it when creating the AWS role and then call this route with your AWS role's arn to link it to your spot account
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object Credentials details | |||
|
{- "credentials": {
- "iamRole": "arn:aws:iam::1234567890:role/Spot_Iam_Role"
}
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/credentials/aws?accountId=act-123456",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Create aws account external id
You should use the external id when creating your AWS role for your spot account
and after you create the role you need to call set-aws-credentials Set Credentials for AWS
to link your AWS account with your spot account
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/setup/credentials/aws/externalId?accountId=act-123456",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:setup:aws:externalId",
- "items": [
- {
- "externalId": "SpotinstAwsAccountExternalId",
- "maxValidUntil": "2021-03-18T16:11:04.402Z"
}
], - "count": 1
}
}
Link a Spot account to a GCP Cloud account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object Set service account for credentials | |||||||||||||||||||||
|
{- "serviceAccount": {
- "type": "service_account",
- "project_id": "test-labs",
- "private_key_id": "XXXXXXXXXXXXXXXXX",
- "private_key": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
- "client_email": "test123@spot.io",
- "client_id": "XXXXXXXXXXXXXXXXXXXXX",
- "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/test123%40test-labs.iam.gserviceaccount.com"
}
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/gcp/setup/credentials?accountId=act-123456",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Validate the credentials for connecting a Spot account to an GCP Cloud account. The validation will test the credentials without actually set it. Please notice to run the set credentials request to perform the set account credentials.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object Set service account for credentials | |||||||||||||||||||||
|
{- "serviceAccount": {
- "type": "service_account",
- "project_id": "test-labs",
- "private_key_id": "XXXXXXXXXXXXXXXXX",
- "private_key": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
- "client_email": "test123@spot.io",
- "client_id": "XXXXXXXXXXXXXXXXXXXXX",
- "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/test123%40test-labs.iam.gserviceaccount.com"
}
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/gcp/setup/credentials/validate?accountId=act-123456",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Link a Spot account to an Azure Cloud account. Enter the expiration date of your Azure client secret. Spot can remind you to update before the credentials expire. If your client secret expires, your Azure subscription will disconnect from Spot and prevent Spot from managing your resources.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
clientId required | string Set the application ID |
clientSecret required | string Set the key secret |
expirationDate required | string <date-time> Set the key secret expiration date |
subscriptionId required | string Set the subscription ID |
tenantId required | string Set the directory ID |
{- "clientId": 111111111,
- "clientSecret": "32431r2431434132",
- "tenantId": "1321e1e3123er23",
- "subscriptionId": "234r3141131",
- "expirationDate": "2025-12-31T23:59:00.000Z"
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/azure/setup/credentials?accountId=act-123456",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Get the credentials connecting a Spot account to an Azure Cloud account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/azure/setup/credentials?accountId=act-123456",
- "method": "GET",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:azure:credentials",
- "items": [
- {
- "clientId": 111111111,
- "tenantId": "1321e1e3123er23",
- "subscriptionId": "234r3141131",
- "clientSecret": "abc*************************************",
- "expirationDate": "2023-10-31T00:00:00Z"
}
], - "count": 1
}
}
Validate the credentials for connecting a Spot account to an Azure Cloud account. The validation will test the credentials without actually set it. Please notice to run the set credentials request to perform the set Azure account credentials (https://docs.spot.io/connect-your-cloud-provider/azure-account) .
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
clientId | string Set the application ID |
clientSecret | string Set the key secret |
subscriptionId | string Set the subscription ID |
tenantId | string Set the directory ID |
{- "clientId": "111111111",
- "clientSecret": "32431r2431434132",
- "tenantId": "1321e1e3123er23",
- "subscriptionId": "234r3141131"
}
{- "request": {
- "id": "46642c7d-bc29-417d-8ce4-79626f00c63c",
- "url": "/azure/setup/credentials/validation?accountId=act-123456",
- "method": "POST",
- "timestamp": "2018-11-19T13:49:11.911Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Sets up and enables Cost Intelligence functionality on a Spot account. The Spot account must already have credentials and be linked to a valid cloud provider account (e.g. AWS account, Azure subscription, etc).
required | object (Account) | ||
|
{- "account": {
- "accountId": "string"
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cbi/v1/setup/account",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "organizationId": "60100100100100",
- "accountId": "act-012345",
- "providerName": "aws",
- "externalProviderId": "012345678901",
- "enabledDate": "2019-08-24T14:15:22Z",
- "updatedDate": "2019-08-24T14:15:22Z"
}
], - "count": 1,
- "kind": "spotinst:cbi:inventory:ciRegisteredAccount"
}
}
Get list of Spot accounts where Cost Intelligence has been setup.
paginationKey | string Key used to fetch a specific page of items |
paginationSize | integer Number of items to include in the response |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cbi/v1/setup/account",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "organizationId": "60100100100100",
- "accountId": "act-012345",
- "providerName": "aws",
- "externalProviderId": "012345678901",
- "enabledDate": "2019-08-24T14:15:22Z",
- "updatedDate": "2019-08-24T14:15:22Z",
- "statusSummary": "connected",
- "status": [
- {
- "productOffering": "common",
- "statusType": "string",
- "statusCode": "string",
- "statusMessage": "string",
- "statistics": {
- "totalResourceTypeCount": 0,
- "failedResourceTypeCount": 0,
- "successfulResourceTypes": [
- "string"
], - "failedResourceTypes": [
- "string"
]
}, - "statusTimestamp": "2019-08-24T14:15:22Z"
}
]
}
], - "count": 1,
- "kind": "string",
- "paginationInfo": {
- "totalCount": 0,
- "nextKey": "string",
- "previousKey": "string"
}
}
}
Validate that Cost Intelligence can be setup on the specified Spot Account.
required | object (Account) | ||
|
{- "account": {
- "accountId": "string"
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cbi/v1/setup/account/validation",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "string",
- "description": "string",
- "status": "success",
- "validationInfo": "string",
- "validationInfoDetails": { }
}
], - "count": 1,
- "kind": "spotinst:cbi:accountRegistrationValidation"
}
}
Get list of Spot accounts where Billing Engine has been setup.
paginationKey | string Key used to fetch a specific page of items |
paginationSize | integer Number of items to include in the response |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cloudBilling/v1/setup/account",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "accountId": "act-23432",
- "organizationId": "634563908342",
- "cloudProvider": "aws",
- "externalProviderId": "435345634",
- "externalProviderName": "Provider account name 1",
- "enabledDate": "2019-08-24T14:15:22Z",
- "updatedDate": "2019-08-24T14:15:22Z",
- "statusSummary": "connected",
- "status": [
- {
- "productOffering": "common",
- "statusType": "string",
- "statusCode": "string",
- "statusMessage": "string",
- "statistics": {
- "totalResourceTypeCount": 0,
- "failedResourceTypeCount": 0,
- "successfulResourceTypes": [
- "string"
], - "failedResourceTypes": [
- "string"
]
}, - "statusTimestamp": "2019-08-24T14:15:22Z"
}
]
}
], - "count": 1,
- "kind": "spotinst:cloudBilling:beRegisteredAccount",
- "paginationInfo": {
- "totalCount": 0,
- "nextKey": "string",
- "previousKey": "string"
}
}
}
Sets up and enables Billing Engine functionality on a Spot account. The Spot account must already have credentials and be linked to a valid cloud provider account (e.g. AWS account, Azure billing account, etc).
accountId required | string Spot Account ID. |
(object or null) or (BERegisteredSetupAccountAwsConfig (object or null)) or (BERegisteredSetupAccountAzureConfig (object or null)) or (BERegisteredSetupAccountGcpConfig (object or null)) Configuration for the Billing Engine (e.g. location of the billing data) |
{- "accountId": "act-23432",
- "config": { }
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cloudBilling/v1/setup/account",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "accountId": "act-23432",
- "organizationId": "634563908342",
- "cloudProvider": "aws",
- "externalProviderId": "435345634",
- "isBillingAccount": true,
- "enabledDate": "2019-08-24T14:15:22Z",
- "updatedDate": "2019-08-24T14:15:22Z",
- "config": { }
}
], - "count": 1,
- "kind": "spotinst:cloudBilling:beRegisteredAccount"
}
}
Validate that Billing Engine can be setup on the specified Spot Account.
accountId required | string Spot Account ID. |
(object or null) or (BERegisteredSetupAccountAwsConfig (object or null)) or (BERegisteredSetupAccountAzureConfig (object or null)) or (BERegisteredSetupAccountGcpConfig (object or null)) Configuration for the Billing Engine (e.g. location of the billing data) |
{- "accountId": "act-23432",
- "config": { }
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/cloudBilling/v1/setup/account/validation",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "string",
- "description": "string",
- "status": "success",
- "validationInfo": "string",
- "validationInfoDetails": { }
}
], - "count": 1,
- "kind": "spotinst:cbi:accountRegistrationValidation"
}
}
Prerequisites
The Ocean Controller is used to monitor the cluster resources and report back to Ocean. The Ocean Controller is required for Ocean Cloud.
To install the Ocean Controller, complete and run the following script on a machine with the kubectl command line tool installed and configured:
#!/usr/bin/env bash
curl -fsSL http://spotinst-public.s3.amazonaws.com/integrations/kubernetes/cluster-controller/scripts/init.sh | \
SPOTINST_TOKEN=<ENTER YOUR TOKEN HERE> \
SPOTINST_ACCOUNT=<ENTER YOUR SPOTINST ACCOUNT ID HERE> \
SPOTINST_CLUSTER_IDENTIFIER=<ENTER YOUR CLUSTER IDENTIFIER HERE> \
bash
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (AWS Cluster) The object specifying the configuration of the Ocean cluster. | ||||||||||||||||||||
|
{- "cluster": {
- "name": "oceanName",
- "controllerClusterId": "ocean.k8s",
- "region": "us-east-1",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVCpu": 750
}, - "down": {
- "maxScaleDownPercentage": 60,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headroom": {
- "cpuPerUnit": 2000,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnits": 4
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true,
- "extendedResourceDefinitions": [
- "erd-123",
- "erd-456"
]
}, - "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "gracePeriod": 300,
- "drainingTimeout": 60,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}, - "spreadNodesBy": "count"
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}, - "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "*.ecr.*.amazonaws.com/*",
- "docker.*"
]
]
}
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-abcd1234",
- "name": "oceanName",
- "controllerClusterId": "ocean.k8s",
- "region": "us-east-1",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVCpu": 750
}, - "down": {
- "maxScaleDownPercentage": 60,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headroom": {
- "cpuPerUnit": 2000,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnits": 4
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true,
- "extendedResourceDefinitions": [
- "erd-123",
- "erd-456"
]
}, - "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "gracePeriod": 300,
- "drainingTimeout": 60,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}, - "spreadNodesBy": "count"
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}, - "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "*.ecr.*.amazonaws.com/*",
- "docker.*"
]
]
}
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s"
}
}
List the configurations for all Ocean clusters in the specified account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-abcd1234",
- "name": "oceanName",
- "controllerClusterId": "ocean.k8s",
- "region": "us-east-1",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVCpu": 750
}, - "down": {
- "maxScaleDownPercentage": 60,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headroom": {
- "cpuPerUnit": 2000,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnits": 4
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true,
- "extendedResourceDefinitions": [
- "erd-123",
- "erd-456"
]
}, - "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "gracePeriod": 300,
- "drainingTimeout": 60,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}, - "spreadNodesBy": "count"
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}, - "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "*.ecr.*.amazonaws.com/*",
- "docker.*"
]
]
}
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s"
}
}
Delete an existing Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-abcd1234",
- "method": "DELETE",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Get the configuration of an existing Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-abcd1234",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-abcd1234",
- "name": "oceanName",
- "controllerClusterId": "ocean.k8s",
- "region": "us-east-1",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVCpu": 750
}, - "down": {
- "maxScaleDownPercentage": 60,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headroom": {
- "cpuPerUnit": 2000,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnits": 4
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true,
- "extendedResourceDefinitions": [
- "erd-123",
- "erd-456"
]
}, - "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "gracePeriod": 300,
- "drainingTimeout": 60,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}, - "spreadNodesBy": "count"
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}, - "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "*.ecr.*.amazonaws.com/*",
- "docker.*"
]
]
}
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s"
}
}
All Ocean parameters are updatable, except for region and identifier. This API supports partial updates, so specific fields can be updated separately.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
autoApplyTags | string Default: "false" Example: autoApplyTags=true Option to update instance tags on the fly without rolling the cluster. |
required | object (AWS Cluster) The object specifying the configuration of the Ocean cluster. | ||||||||||||||||||||
|
{- "cluster": {
- "name": "oceanName",
- "controllerClusterId": "ocean.k8s",
- "region": "us-east-1",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVCpu": 750
}, - "down": {
- "maxScaleDownPercentage": 60,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headroom": {
- "cpuPerUnit": 2000,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnits": 4
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true,
- "extendedResourceDefinitions": [
- "erd-123",
- "erd-456"
]
}, - "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "gracePeriod": 300,
- "drainingTimeout": 60,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}, - "spreadNodesBy": "count"
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}, - "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "*.ecr.*.amazonaws.com/*",
- "docker.*"
]
]
}
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-abcd1234",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-abcd1234",
- "name": "oceanName",
- "controllerClusterId": "ocean.k8s",
- "region": "us-east-1",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVCpu": 750
}, - "down": {
- "maxScaleDownPercentage": 60,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headroom": {
- "cpuPerUnit": 2000,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnits": 4
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true,
- "extendedResourceDefinitions": [
- "erd-123",
- "erd-456"
]
}, - "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "gracePeriod": 300,
- "drainingTimeout": 60,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}, - "spreadNodesBy": "count"
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}, - "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "*.ecr.*.amazonaws.com/*",
- "docker.*"
]
]
}
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s"
}
}
Get the heartbeat status of the Ocean Controller for the cluster.
The response returns the heartbeat status and the last heartbeat timestamp.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/k8s/cluster/o-e0a2bd7c/controllerHeartbeat",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "status": "ACTIVE",
- "lastHeartbeat": "2019-11-24T14:33:00.746Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:k8s:cluster:controllerHeartbeat"
}
}
Fetch the log of an Ocean cluster.
clusterIdentifier required | string Example: o-6e3819ae The reporting identifier of the Ocean Controller. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
fromDate required | string Beginning date value using either the date format "yyyy-mm-dd; 2016-11-20" or ms "1494751821472". |
limit | integer <= 1000 Default: 500 Example: limit=200 Maximum number of lines to extract in a response. |
resourceId | string Example: resourceId=i-12345678 Filter extracted log entries for a specific resource identifier. Default: Null |
severity | string Default: "ALL" Enum: "ALL" "INFO" "DEBUG" "ERROR" "WARN" Example: severity=INFO Severity of log entries to extract. |
toDate required | string End date value using either the date format "yyyy-mm-dd; 2016-11-20" or ms "1494751821472". |
{- "request": {
- "id": "3213f42e-455e-4801-a185-cd3eb65fac5f",
- "url": "/ocean/aws/k8s/cluster/o-e0a2bd7c/log?fromDate=2020-10-06&toDate=2020-10-08&severity=ALL&limit=500",
- "method": "GET",
- "timestamp": "2020-10-05T16:20:38.579Z"
}, - "response": {
- "status": {
- "code": "200",
- "message": "OK"
}, - "kind": "spotinst:ocean:cluster:log",
- "items": [
- {
- "message": "Ocean o-e0a2bd7c successfully created.",
- "severity": "INFO",
- "createdAt": "2020-10-07T09:51:12.000Z"
}
], - "count": "1"
}
}
Create an Ocean configuration according to an AWS autoscaling group (ASG) configuration.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
autoScalingGroupName required | string Example: autoScalingGroupName=myAutoScalingGroup The ASG name. |
region required | string Example: region=us-east-1 Region name of the ASG. |
object The object specifying the configuration of the VNG. | |||
|
{- "cluster": {
- "instanceTypes": [
- "c3.large",
- "m4.large"
]
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/autoScalingGroup/import",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "name": "TestASG1",
- "controllerClusterId": "ocean-ed609402-8557-4d18-818a-e549333cc11e",
- "region": "us-west-2",
- "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "compute": {
- "subnetIds": [
- [
- "subnet-00cab2dd9f40a9883",
- "subnet-0df9d512c7cbbd9e1"
]
], - "launchSpecification": {
- "securityGroupIds": [
- [
- "sg-03ccf232a2bf0f4ea"
]
], - "keyPair": "testteamkp",
- "imageId": "ami-0ce21b51cb31a54b8",
- "tags": {
- "tagKey": "AmazonECSManaged",
- "tagValue": ""
}, - "associatePublicIpAddress": "false",
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}
}
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s"
}
}
Get right-sizing recommendations for an Ocean cluster and filter them according to namespace or label.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object Optional - may be null. | |||||
|
{- "filter": {
- "namespaces": [
- "sparkSpace",
- "kube-system"
], - "attribute": {
- "type": "label",
- "key": "app",
- "operator": "Equals",
- "value": "redis"
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-abcd1234/rightSizing/suggestion",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "resourceName": "redis-controller",
- "resourceType": "deployment",
- "namespace": "kube-system",
- "suggestedCPU": 4,
- "suggestedMemory": 19,
- "requestedCPU": 50,
- "requestedMemory": 50,
- "containers": [
- {
- "name": "dnsmasq",
- "requestedCPU": 10,
- "suggestedCPU": 2,
- "requestedMemory": 40,
- "suggestedMemory": 15
}, - {
- "name": "sidecar",
- "requestedCPU": 40,
- "suggestedCPU": 2,
- "requestedMemory": 10,
- "suggestedMemory": 4
}
]
}, - {
- "resourceName": "test-redis",
- "resourceType": "deployment",
- "namespace": "sparkSpace",
- "suggestedCPU": 2,
- "suggestedMemory": 20,
- "requestedCPU": 50,
- "requestedMemory": 30,
- "containers": [
- {
- "name": "dns-controller",
- "requestedCPU": 20,
- "suggestedCPU": 1,
- "requestedMemory": 20,
- "suggestedMemory": 15
}, - {
- "name": "kubedns",
- "requestedCPU": 30,
- "suggestedCPU": 1,
- "requestedMemory": 10,
- "suggestedMemory": 5
}
]
}
], - "count": 2,
- "kind": "spotinst:ocean:aws:k8s:cluster:rightSizing:suggestion"
}
}
Returns all instances types that match the given filters. These instance types will be used if the cluster is configured with these filters.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (InstanceTypesFilters) List of filters. The Instance types that match with all filters compose the Ocean's whitelist parameter. Cannot be configured together with whitelist/blacklist. | ||||||||||||||||||||||||||||||||||||||
|
{- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-abcd1234/instanceTypeFiltersSimulation",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "filteredInstanceTypes": [
- "g5.xlarge",
- "c5.2xlarge",
- "c5ad.2xlarge",
- "c5d.2xlarge",
- "c5a.2xlarge"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:instanceTypesFilters:simulation"
}
}
Return the list of the allowed Ocean cluster instance types.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-12345abc/allowedInstanceTypes",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "instanceTypes": [
- "c3.large",
- "c5.large"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:allowedInstanceTypes"
}
}
Add new load balancers to the existing load balancers on the Ocean Cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | Array of objects (ocean-lb) Load balancers to add to the Ocean cluster. | ||||||
Array
|
{- "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
]
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-12345abc/loadBalancer/attach",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-abcd1234",
- "name": "oceanName",
- "controllerClusterId": "ocean.k8s",
- "region": "us-east-1",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVCpu": 750
}, - "down": {
- "maxScaleDownPercentage": 60,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headroom": {
- "cpuPerUnit": 2000,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnits": 4
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true,
- "extendedResourceDefinitions": [
- "erd-123",
- "erd-456"
]
}, - "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "gracePeriod": 300,
- "drainingTimeout": 60,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}, - "spreadNodesBy": "count"
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}, - "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "*.ecr.*.amazonaws.com/*",
- "docker.*"
]
]
}
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s"
}
}
Remove load balancers from the existing load balancers on the Ocean Cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | Array of objects (ocean-lb) Load balancers to remove from the Ocean cluster. | ||||||
Array
|
{- "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
]
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-12345abc/loadBalancer/detach",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-abcd1234",
- "name": "oceanName",
- "controllerClusterId": "ocean.k8s",
- "region": "us-east-1",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVCpu": 750
}, - "down": {
- "maxScaleDownPercentage": 60,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headroom": {
- "cpuPerUnit": 2000,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnits": 4
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true,
- "extendedResourceDefinitions": [
- "erd-123",
- "erd-456"
]
}, - "capacity": {
- "minimum": 0,
- "maximum": 1000,
- "target": 1
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "gracePeriod": 300,
- "drainingTimeout": 60,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}, - "spreadNodesBy": "count"
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}, - "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "*.ecr.*.amazonaws.com/*",
- "docker.*"
]
]
}
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s"
}
}
Upgrade an Elastigroup with Kubernetes integration to Ocean for Kubernetes cluster.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
groupId required | string Elastigroup identifier |
{- "kind": "spotinst:ocean:aws:k8s",
- "items": {
- "id": "o-482d9d26",
- "name": "Ocean::test-k8s-batch-1",
- "clusterName": "testEnvironment_Batch_852a670a-aa73-3d5d-9576-147a26d43401",
- "autoScaler": {
- "isEnabled": true,
- "isAutoConfig": true
}, - "region": "us-west-2",
- "groupId": "sig-b6bb68fb",
- "strategy": {
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 120
}, - "compute": {
- "subnetIds": [
- "subnet-4c1d1538",
- "subnet-2791bb61"
], - "instanceTypes": {
- "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}, - "launchSpecification": {
- "useAsTemplateOnly": false,
- "imageId": "string",
- "userData": "string",
- "securityGroupIds": [
- [
- "sg-c3d914b0"
]
], - "iamInstanceProfile": {
- "arn": "orform"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "dynamicIops": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}, - "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "keyPair": "spotinst-labs-oregon",
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "loadBalancers": [
- {
- "type": "TARGET_GROUP",
- "name": "MyTargetGroup",
- "arn": "arn:aws:elasticloadbalancing:us-west-2:922761411234:targetgroup"
}
], - "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "monitoring": true,
- "ebsOptimized": true,
- "rootVolumeSize": 73,
- "reservedENIs": 1,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled"
}, - "resourceTagSpecification": {
- "volumes": {
- "shouldTag": false
}
}, - "healthCheckUnhealthyDurationBeforeReplacement": 60,
- "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}, - "createdAt": "2018-11-05T12:55:50.000+0000",
- "updatedAt": "2018-11-05T12:58:15.000+0000"
}
}
Roll an entire Ocean cluster or roll subsets of the cluster by specifying launchSpecIds or instanceIds. Performing this request will start the roll immediately and run it in defined batches. Note that the first response for a successful request will indicate the start of a roll. In order to check the status of a roll, you can use the GET Roll API.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object | |||||||||
|
{- "roll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "respectPdb": true,
- "batchMinHealthyPercentage": 100
}
}
{- "id": "scr-5aaf854e",
- "scope": "Cluster",
- "status": "IN_PROGRESS",
- "currentBatch": 1,
- "numOfBatches": 5,
- "comment": "This is why I deployed my cluster.",
- "progress": {
- "unit": "percentage",
- "value": 0,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceId": "i-003a0281a24c01a20",
- "status": "REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a21",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a22",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a23",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}
]
}
}, - "oceanId": "o-12e31234",
- "instanceIds": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
], - "launchSpecIds": [
- "ols-76694a7d",
- "ols-56694a76"
], - "respectPdb": true,
- "batchMinHealthyPercentage": 100,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
Get status for all rolls of an Ocean cluster.
oceanClusterId required | string Example: o-1abcd124 The identifier of the Ocean cluster |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:ocean:aws:k8s:cluster:roll",
- "items": [
- {
- "id": "scr-5aaf854e",
- "scope": "Cluster",
- "status": "IN_PROGRESS",
- "currentBatch": 1,
- "numOfBatches": 5,
- "comment": "This is why I deployed my cluster.",
- "progress": {
- "unit": "percentage",
- "value": 0,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceId": "i-003a0281a24c01a20",
- "status": "REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a21",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a22",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a23",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}
]
}
}, - "oceanId": "o-12e31234",
- "instanceIds": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
], - "launchSpecIds": [
- "ols-76694a7d",
- "ols-56694a76"
], - "respectPdb": true,
- "batchMinHealthyPercentage": 100,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
]
}
Update a roll of an Ocean cluster.
Performing the request will stop the next batch in a roll.
oceanClusterId required | string Example: o-1abcd124 The identifier of the Ocean cluster |
ROLL_ID required | string Example: scr-12345abc Ocean cluster roll identifier |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object Object that specifies the parameters required to initiate a roll (also called a deployment). | ||
|
{- "roll": {
- "status": "STOPPED"
}
}
{- "id": "scr-5aaf854e",
- "scope": "Cluster",
- "status": "STOPPED",
- "currentBatch": 1,
- "numOfBatches": 5,
- "progress": {
- "unit": "percentage",
- "value": 0,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceId": "i-003a0281a24c01a20",
- "status": "REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a21",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a22",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a23",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}
]
}
}, - "oceanId": "o-12e31234",
- "respectPdb": true,
- "batchMinHealthyPercentage": 100,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
Get status for a roll of an Ocean cluster.
oceanClusterId required | string Example: o-1abcd124 The identifier of the Ocean cluster |
ROLL_ID required | string Example: scr-12345abc Ocean Cluster Roll identifier |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "id": "scr-5aaf854e",
- "scope": "Cluster",
- "status": "IN_PROGRESS",
- "currentBatch": 1,
- "numOfBatches": 5,
- "comment": "This is why I deployed my cluster.",
- "progress": {
- "unit": "percentage",
- "value": 0,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceId": "i-003a0281a24c01a20",
- "status": "REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a21",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a22",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a23",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}
]
}
}, - "oceanId": "o-12e31234",
- "instanceIds": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
], - "launchSpecIds": [
- "ols-76694a7d",
- "ols-56694a76"
], - "respectPdb": true,
- "batchMinHealthyPercentage": 100,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
Get nodes data of an Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
instanceId | string Example: instanceId=i-123 Get a specific node by instance id. |
launchSpecId | string Example: launchSpecId=ols-123abc Ocean cluster Virtual Node Group identifier. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-12345abc/nodes",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "instanceId": "i-123",
- "instanceType": "c3.large",
- "availabilityZone": "us-west-2b",
- "launchSpecId": "ols-123",
- "launchSpecName": "dev-vng",
- "lifeCycle": "Spot",
- "publicIp": "1.2.3.4",
- "workloadRequestedMilliCpu": 1320,
- "workloadRequestedMemoryInMiB": 500,
- "workloadRequestedGpu": 1,
- "headroomRequestedMilliCpu": 1320,
- "headroomRequestedMemoryInMiB": 512,
- "headroomRequestedGpu": 1,
- "allocatableMilliCpu": 2000,
- "allocatableMemoryInMiB": 3646.1,
- "allocatableGpu": 1,
- "nodeName": "node-1",
- "registrationStatus": "Registered",
- "createdAt": "2021-10-1T05:51:06.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:nodes"
}
}
Detach instances from your Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
instancesToDetach required | Array of strings Array of instance identifiers to be detached. |
shouldDecrementTargetCapacity | boolean Determines whether the Ocean cluster's target capacity should be decremented. |
shouldTerminateInstances | boolean Determines whether the detached EC2 instances should be terminated or not. |
{- "instancesToDetach": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
], - "shouldTerminateInstances": true,
- "shouldDecrementTargetCapacity": false
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-abcd1234/detachInstances",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Provides Kubernetes cluster resource usage and costs over a time interval which can be grouped and/or filtered by label/annotaion.
For example - application name (webapp, backend), environment (production, staging), version etc.
The response will contain a breakdown of the cluster resource costs($) in terms of compute (CPU, memory), storage (block, file, rootVolume).
The response will group the cluster usage costs based on preselected default of application namespace or user selected label or annotation.
Within the group, resource costs are broken down per resource kind (Deployment, DaemonSet etc.).
Time Rounding Down: The CostAnalysis API applies rounding down to the hours provided during the call.
For example, the value 1707004799099 (In GMT) representing Saturday, February 3, 2024, 23:59:59.099 is rounded down to Saturday, February 3, 2024, 23:00:00.000, resulting in the omission of one hour of cost.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
endTime required | string End date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
object Describe how to filter the costs. Optional field. | |
groupBy | string Default: "namespace" Enum: "namespace" "namespace.label.${labelKey}" "resource.label.${labelKey}" "resource.annotation.${annotationKey}" "namespace.annotation.${annotationKey}" The parameter we want to group the costs by. |
startTime required | string Beginning date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
{- "startTime": "2018-06-20T11:35:02.745Z",
- "endTime": "2018-06-22T11:30:01.745Z",
- "groupBy": "namespace.label.env",
- "filter": {
- "scope": "namespace",
- "conditions": {
- "anyMatch": [
- {
- "allMatch": [
- {
- "type": "label",
- "key": "env",
- "operator": "equals",
- "value": "prod"
}, - {
- "type": "label",
- "key": "app",
- "operator": "exists"
}
]
}, - {
- "allMatch": [
- {
- "type": "annotation",
- "key": "meta.data",
- "operator": "exists"
}
]
}
]
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-abcd1234/aggregatedCosts",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "result": {
- "totalForDuration": {
- "startTime": "2018-06-20T11:35:01.745Z",
- "endTime": "2018-06-22T11:30:01.745Z",
- "summary": {
- "total": 41772.882658035785,
- "compute": {
- "total": 40668.1299631538,
- "workloads": {
- "total": 39882.13803327978
}, - "headroom": {
- "total": 0
}
}, - "storage": {
- "total": 1104.7526948819868,
- "block": {
- "total": 1104.7526948819868,
- "ebsPv": {
- "total": 1104.7526948819868
}, - "nonPv": {
- "total": 0
}
}, - "file": {
- "total": 0,
- "efsPv": {
- "total": 0
}
}
}, - "networking": {
- "totalCost": 0.00278988928,
- "totalUsage": 0.03154064,
- "total": {
- "in": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}, - "out": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}
}, - "internet": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interAZ": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}, - "intraAZ": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interRegion": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}
}
}, - "detailedCosts": {
- "groupedBy": "n.l.name",
- "aggregations": {
- "property1": {
- "summary": {
- "total": 423.33455,
- "compute": {
- "total": 125.23778
}, - "storage": {
- "total": 307.09677,
- "block": {
- "total": 300,
- "ebsPv": {
- "total": 300
}, - "nonPv": {
- "total": 0
}
}, - "file": {
- "total": 7.09677,
- "efsPv": {
- "total": 7.09677
}
}
}, - "networking": {
- "totalCost": 0.00278988928,
- "totalUsage": 0.03154064,
- "total": {
- "in": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}, - "out": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}
}, - "internet": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interAZ": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}, - "intraAZ": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interRegion": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}
}
}, - "resources": [
- {
- "metadata": {
- "name": "k8s-events",
- "type": "Deployment",
- "namespace": "kube-system"
}, - "total": 1.655635222089105,
- "compute": {
- "total": 1.4213600158059045
}, - "storage": {
- "total": 0.23427520628320053,
- "block": {
- "total": 0.23427520628320053,
- "ebsPv": {
- "total": 0
}, - "nonPv": {
- "total": 0.23427520628320053
}
}, - "file": {
- "total": 0,
- "efsPv": {
- "total": 0
}
}
}, - "networking": {
- "totalCost": 0.00278988928,
- "totalUsage": 0.03154064,
- "total": {
- "in": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}, - "out": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}
}, - "internet": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interAZ": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}, - "intraAZ": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interRegion": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}
}
}
]
}, - "property2": {
- "summary": {
- "total": 423.33455,
- "compute": {
- "total": 125.23778
}, - "storage": {
- "total": 307.09677,
- "block": {
- "total": 300,
- "ebsPv": {
- "total": 300
}, - "nonPv": {
- "total": 0
}
}, - "file": {
- "total": 7.09677,
- "efsPv": {
- "total": 7.09677
}
}
}, - "networking": {
- "totalCost": 0.00278988928,
- "totalUsage": 0.03154064,
- "total": {
- "in": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}, - "out": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}
}, - "internet": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interAZ": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}, - "intraAZ": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interRegion": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}
}
}, - "resources": [
- {
- "metadata": {
- "name": "k8s-events",
- "type": "Deployment",
- "namespace": "kube-system"
}, - "total": 1.655635222089105,
- "compute": {
- "total": 1.4213600158059045
}, - "storage": {
- "total": 0.23427520628320053,
- "block": {
- "total": 0.23427520628320053,
- "ebsPv": {
- "total": 0
}, - "nonPv": {
- "total": 0.23427520628320053
}
}, - "file": {
- "total": 0,
- "efsPv": {
- "total": 0
}
}
}, - "networking": {
- "totalCost": 0.00278988928,
- "totalUsage": 0.03154064,
- "total": {
- "in": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}, - "out": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}
}, - "internet": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interAZ": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}, - "intraAZ": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interRegion": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}
}
}
]
}
}
}
}
}
}
], - "count": 1,
- "kind": "ocean:k8s:cluster:aggregatedCosts:detailed"
}
}
Provides Kubernetes cluster summary usage and costs over a time interval which can be grouped and/or filtered by label/annotaion,
for example - application name (webapp, backend), environment (production, staging), version etc.
The response will contain a breakdown of the cluster resource costs($) in terms of compute (CPU, memory), storage (block, file, rootVolume).
The response will group the cluster usage costs based on preselected default of application namespace or user selected label or annotation.
Time Rounding Down: The CostAnalysis API applies rounding down to the hours provided during the call.
For example, the value 1707004799099 (In GMT) representing Saturday, February 3, 2024, 23:59:59.099 is rounded down to Saturday, February 3, 2024, 23:00:00.000, resulting in the omission of one hour of cost.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
endTime required | string End date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
object Describe how to filter the costs. Optional field. | |
groupBy | string Default: "namespace" Enum: "namespace" "namespace.label.${labelKey}" "resource.label.${labelKey}" "resource.annotation.${annotationKey}" "namespace.annotation.${annotationKey}" The parameter we want to group the costs by. |
startTime required | string Beginning date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
{- "startTime": "2018-06-20T11:35:02.745Z",
- "endTime": "2018-06-22T11:30:01.745Z",
- "groupBy": "namespace.label.env",
- "filter": {
- "scope": "namespace",
- "conditions": {
- "anyMatch": [
- {
- "allMatch": [
- {
- "type": "label",
- "key": "env",
- "operator": "equals",
- "value": "prod"
}, - {
- "type": "label",
- "key": "app",
- "operator": "exists"
}
]
}, - {
- "allMatch": [
- {
- "type": "annotation",
- "key": "meta.data",
- "operator": "exists"
}
]
}
]
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/cluster/o-abcd1234/aggregatedCosts/summary",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "result": {
- "totalForDuration": {
- "startTime": "2018-06-20T11:35:01.745Z",
- "endTime": "2018-06-22T11:30:01.745Z",
- "summary": {
- "total": 41772.882658035785,
- "compute": {
- "total": 40668.1299631538,
- "workloads": {
- "total": 39882.13803327978
}, - "headroom": {
- "total": 0
}
}, - "storage": {
- "total": 1104.7526948819868,
- "block": {
- "total": 1104.7526948819868,
- "ebsPv": {
- "total": 1104.7526948819868
}, - "nonPv": {
- "total": 0
}
}, - "file": {
- "total": 0,
- "efsPv": {
- "total": 0
}
}
}, - "networking": {
- "totalCost": 0.00278988928,
- "totalUsage": 0.03154064,
- "total": {
- "in": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}, - "out": {
- "cost": 0.00139494464,
- "usage": 0.01577032
}
}, - "internet": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interAZ": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}, - "intraAZ": {
- "in": {
- "cost": 0.000693972,
- "usage": 0.0077108
}, - "out": {
- "cost": 0.000693972,
- "usage": 0.0077108
}
}, - "interRegion": {
- "in": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}, - "out": {
- "cost": 0.0000035003200000000003,
- "usage": 0.000175016
}
}
}
}
}
}
}
], - "count": 1,
- "kind": "ocean:k8s:cluster:aggregatedCosts:summary"
}
}
Update the Ocean EKS cluster's VNGs with the latest image or the image matching the control plane's version after upgrading, by specifying ‘patch' or 'minorVersion’. Performing this request will update the VNGs with new AMI if available, and run a cluster roll if set. If the response is successful, the old and new AMIs will be included in the response along with the updated VNGs. If a cluster roll is set in the request, the first response for a successful request will indicate the start of a roll. In order to check the status of the roll, you can use the GET Roll API.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object | |||||||||
|
{- "amiAutoUpdate": {
- "patch": true,
- "minorVersion": true,
- "applyRoll": true,
- "clusterRoll": {
- "batchSizePercentage": 20,
- "batchMinHealthyPercentage": 100,
- "comment": "This is why I rolled my cluster.",
- "respectPdb": true
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/eks/cluster/o-abcd1234/amiAutoUpdate",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-134abcd",
- "status": "Success",
- "data": [
- {
- "vngId": "default",
- "vngName": "default",
- "status": "UPDATE_SUCCEEDED",
- "updateType": "MINOR",
- "oldAmiId": "ami-00cd348996bfd7ba8",
- "newAmiId": "ami-019e5b81636e5a350"
}
], - "rollId": "scr-752331b9",
- "createdAt": "2024-01-02T09:57:09.211Z",
- "updatedAt": "2024-01-02T09:57:09.211Z"
}
], - "count": 1,
- "kind": "ocean:k8s:cluster:amiAutoUpdate:summary"
}
}
Create a Virtual Node Group.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
initialNodes | integer Default: null Example: initialNodes=1 When set to an integer greater than 0, a corresponding number of nodes will be launched from the virtual node group created. |
required | object (oceanClusterLaunchSpecWithMetadata) AWS Cluster Virtual Node Group (VNG). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
{- "launchSpec": {
- "oceanId": "o-abcd1234",
- "name": "specialty.nodes.spotk8s.com",
- "imageId": "ami-ID",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dsa89d7uosduxq98sau9s8aux9s8aux09q0qu09axsuix0s9qas09xz",
- "iamInstanceProfile": {
- "arn": "arn:aws:iam::123456781234:instance-profile/EKS-nodes-test-NodeInstanceProfile-ABCDEFGH123",
- "name": "EKS-nodes-test"
}, - "securityGroupIds": [
- "sg-0ded3a2980208c30c",
- "sg-0ded3a2980208c30d"
], - "instanceTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "instanceTypesFilters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "preferredOnDemandTypes": [
- "c3.large",
- "m4.xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "rootVolumeSize": 8,
- "reservedENIs": 1,
- "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "subnetIds": [
- "subnet-123",
- "subnet-456"
], - "elasticIpPool": {
- "tagSelector": {
- "tagKey": "color",
- "tagValue": "orange"
}
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 0
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "ephemeralStorage": {
- "deviceName": "/dev/xvdb"
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "strategy": {
- "spotPercentage": 70,
- "utilizeReservedInstances": true,
- "utilizeCommitments": false,
- "drainingTimeout": 300,
- "orientation": {
- "availabilityVsCost": "balanced"
}
}, - "associatePublicIpAddress": false,
- "restrictScaleDown": false,
- "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 1
}
]
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ols-12345abc",
- "oceanId": "o-abcd1234",
- "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z",
- "name": "specialty.nodes.spotk8s.com",
- "imageId": "ami-ID",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dsa89d7uosduxq98sau9s8aux9s8aux09q0qu09axsuix0s9qas09xz",
- "iamInstanceProfile": {
- "arn": "arn:aws:iam::123456781234:instance-profile/EKS-nodes-test-NodeInstanceProfile-ABCDEFGH123",
- "name": "EKS-nodes-test"
}, - "securityGroupIds": [
- "sg-0ded3a2980208c30c",
- "sg-0ded3a2980208c30d"
], - "instanceTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "instanceTypesFilters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "preferredOnDemandTypes": [
- "c3.large",
- "m4.xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "rootVolumeSize": 8,
- "reservedENIs": 1,
- "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "subnetIds": [
- "subnet-123",
- "subnet-456"
], - "elasticIpPool": {
- "tagSelector": {
- "tagKey": "color",
- "tagValue": "orange"
}
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 0
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "ephemeralStorage": {
- "deviceName": "/dev/xvdb"
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "strategy": {
- "spotPercentage": 70,
- "utilizeReservedInstances": true,
- "utilizeCommitments": false,
- "drainingTimeout": 300,
- "orientation": {
- "availabilityVsCost": "balanced"
}
}, - "associatePublicIpAddress": false,
- "restrictScaleDown": false,
- "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 1
}
]
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec"
}
}
List the configurations of all virtual node groups for the cluster.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
oceanId | string Example: oceanId=o-12345abc Identifier of the Ocean cluster. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ols-12345abc",
- "oceanId": "o-abcd1234",
- "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z",
- "name": "specialty.nodes.spotk8s.com",
- "imageId": "ami-ID",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dsa89d7uosduxq98sau9s8aux9s8aux09q0qu09axsuix0s9qas09xz",
- "iamInstanceProfile": {
- "arn": "arn:aws:iam::123456781234:instance-profile/EKS-nodes-test-NodeInstanceProfile-ABCDEFGH123",
- "name": "EKS-nodes-test"
}, - "securityGroupIds": [
- "sg-0ded3a2980208c30c",
- "sg-0ded3a2980208c30d"
], - "instanceTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "instanceTypesFilters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "preferredOnDemandTypes": [
- "c3.large",
- "m4.xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "rootVolumeSize": 8,
- "reservedENIs": 1,
- "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "subnetIds": [
- "subnet-123",
- "subnet-456"
], - "elasticIpPool": {
- "tagSelector": {
- "tagKey": "color",
- "tagValue": "orange"
}
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 0
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "ephemeralStorage": {
- "deviceName": "/dev/xvdb"
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "strategy": {
- "spotPercentage": 70,
- "utilizeReservedInstances": true,
- "utilizeCommitments": false,
- "drainingTimeout": 300,
- "orientation": {
- "availabilityVsCost": "balanced"
}
}, - "associatePublicIpAddress": false,
- "restrictScaleDown": false,
- "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 1
}
]
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec"
}
}
Delete a specified Virtual Node Group in an Ocean cluster.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
deleteNodes | boolean Default: false Example: deleteNodes=true When set to "true", all instances belonging to the deleted Virtual Node Group will be drained, detached, and terminated. |
forceDelete | boolean Default: null Example: forceDelete=true When set to "true", delete even if it is the only custom Virtual Node Group remaining, and default Virtual Node Group has useAsTemlateOnly = true. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec/ols-12345abc",
- "method": "DELETE",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Update Virtual Node Group.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
autoApplyTags | boolean Default: false Example: autoApplyTags=true Optionally update resource tags on the fly without performing a roll. |
required | object (oceanClusterLaunchSpec) AWS Cluster Virtual Node Group (VNG). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
{- "launchSpec": {
- "name": "specialty.nodes.spotk8s.com",
- "imageId": "ami-ID",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dsa89d7uosduxq98sau9s8aux9s8aux09q0qu09axsuix0s9qas09xz",
- "iamInstanceProfile": {
- "arn": "arn:aws:iam::123456781234:instance-profile/EKS-nodes-test-NodeInstanceProfile-ABCDEFGH123",
- "name": "EKS-nodes-test"
}, - "securityGroupIds": [
- "sg-0ded3a2980208c30c",
- "sg-0ded3a2980208c30d"
], - "instanceTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "instanceTypesFilters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "preferredOnDemandTypes": [
- "c3.large",
- "m4.xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "rootVolumeSize": 8,
- "reservedENIs": 1,
- "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "subnetIds": [
- "subnet-123",
- "subnet-456"
], - "elasticIpPool": {
- "tagSelector": {
- "tagKey": "color",
- "tagValue": "orange"
}
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 0
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "ephemeralStorage": {
- "deviceName": "/dev/xvdb"
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "strategy": {
- "spotPercentage": 70,
- "utilizeReservedInstances": true,
- "utilizeCommitments": false,
- "drainingTimeout": 300,
- "orientation": {
- "availabilityVsCost": "balanced"
}
}, - "associatePublicIpAddress": false,
- "restrictScaleDown": false,
- "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 1
}
]
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec/ols-12345abc",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ols-12345abc",
- "oceanId": "o-abcd1234",
- "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z",
- "name": "specialty.nodes.spotk8s.com",
- "imageId": "ami-ID",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dsa89d7uosduxq98sau9s8aux9s8aux09q0qu09axsuix0s9qas09xz",
- "iamInstanceProfile": {
- "arn": "arn:aws:iam::123456781234:instance-profile/EKS-nodes-test-NodeInstanceProfile-ABCDEFGH123",
- "name": "EKS-nodes-test"
}, - "securityGroupIds": [
- "sg-0ded3a2980208c30c",
- "sg-0ded3a2980208c30d"
], - "instanceTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "instanceTypesFilters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "preferredOnDemandTypes": [
- "c3.large",
- "m4.xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "rootVolumeSize": 8,
- "reservedENIs": 1,
- "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "subnetIds": [
- "subnet-123",
- "subnet-456"
], - "elasticIpPool": {
- "tagSelector": {
- "tagKey": "color",
- "tagValue": "orange"
}
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 0
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "ephemeralStorage": {
- "deviceName": "/dev/xvdb"
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "strategy": {
- "spotPercentage": 70,
- "utilizeReservedInstances": true,
- "utilizeCommitments": false,
- "drainingTimeout": 300,
- "orientation": {
- "availabilityVsCost": "balanced"
}
}, - "associatePublicIpAddress": false,
- "restrictScaleDown": false,
- "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 1
}
]
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec"
}
}
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec/ols-12345abc",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ols-12345abc",
- "oceanId": "o-abcd1234",
- "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z",
- "name": "specialty.nodes.spotk8s.com",
- "imageId": "ami-ID",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dsa89d7uosduxq98sau9s8aux9s8aux09q0qu09axsuix0s9qas09xz",
- "iamInstanceProfile": {
- "arn": "arn:aws:iam::123456781234:instance-profile/EKS-nodes-test-NodeInstanceProfile-ABCDEFGH123",
- "name": "EKS-nodes-test"
}, - "securityGroupIds": [
- "sg-0ded3a2980208c30c",
- "sg-0ded3a2980208c30d"
], - "instanceTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "instanceTypesFilters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "preferredOnDemandTypes": [
- "c3.large",
- "m4.xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "rootVolumeSize": 8,
- "reservedENIs": 1,
- "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "subnetIds": [
- "subnet-123",
- "subnet-456"
], - "elasticIpPool": {
- "tagSelector": {
- "tagKey": "color",
- "tagValue": "orange"
}
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 0
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "ephemeralStorage": {
- "deviceName": "/dev/xvdb"
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "strategy": {
- "spotPercentage": 70,
- "utilizeReservedInstances": true,
- "utilizeCommitments": false,
- "drainingTimeout": 300,
- "orientation": {
- "availabilityVsCost": "balanced"
}
}, - "associatePublicIpAddress": false,
- "restrictScaleDown": false,
- "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2,
- "gpuPerUnit": 1
}
]
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "startupTaints": [
- {
- "key": "node.cilium.io/agent-not-ready",
- "value": true,
- "effect": "NoSchedule"
}
], - "instanceStorePolicy": {
- "type": "RAID0"
}, - "gpu": {
- "sharing": [
- {
- "gpuSharingType": "timeSlicing",
- "config": {
- "replicas": 2
}
}
]
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec"
}
}
Returns all instance types that match the given filters. These instance types will be used if the Virtual Node Group is configured with these filters.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (InstanceTypesFilters) List of instance types filters. The instance types that match with all filters compose the Virtual Node Group's instanceTypes parameter. | ||||||||||||||||||||||||||||||||||||
|
{- "instanceTypesFilters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchspec/o-abcd1234/instanceTypeFiltersSimulation",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "filteredInstanceTypes": [
- "g5.xlarge",
- "c5.2xlarge",
- "c5ad.2xlarge",
- "c5d.2xlarge",
- "c5a.2xlarge"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec:instanceTypesFilters:simulation"
}
}
Returns the Virtual Node Group's instance types when instance types filters is set.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec/ols-12345abc/allowedInstanceTypesByFilters",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "instanceTypes": [
- "c3.large",
- "c5.large"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec:allowedInstanceTypesByFilters"
}
}
Returns an Ocean Virtual Node Group (VNG) configuration in a given AWS autoscaling group (ASG). The returned value ("Imported VNG") can then be used as input to the Create Virtual Node Group API in order to create an actual VNG in your Ocean cluster.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
autoScalingGroupName required | string Example: autoScalingGroupName=myAutoScalingGroup The ASG name. |
oceanId required | string Example: oceanId=o-12345abc Identifier of the Ocean cluster. |
object The object specifying the configuration of the VNG. | |||||||
|
{- "launchSpec": {
- "name": "specialty.nodes.spotk8s.com",
- "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
]
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec/autoScalingGroup/import",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-500a5d5a",
- "name": "TestTeam1",
- "imageId": "ami-0ce21b51cb55a48b8",
- "securityGroupIds": [
- [
- "sg-03ccf232a2bf0f4ea"
]
], - "tags": {
- "tagKey": "AmazonECSManaged",
- "tagValue": ""
}, - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec"
}
}
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
eksClusterName required | string Example: eksClusterName=MyEksCluster Cluster name of the EKS cluster. |
eksNodeGroupName required | string Example: eksNodeGroupName=MyEksClusterNodeGroup Node group name to import. |
oceanId | string Example: oceanId=o-12345abc Identifier of the Ocean cluster. |
region | string Example: region=us-east-1 Region name of the EKS cluster's node group. |
object The object specifying the configuration of the VNG. | |||||
|
{- "launchSpec": {
- "name": "specialty.nodes.spotk8s.com",
- "labels": [
- {
- "key": "env",
- "value": "test"
}
]
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec/eksNodeGroup/import",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-500a5d5a",
- "name": "TestTeam1",
- "imageId": "ami-0ce21b51cb55a48b8",
- "securityGroupIds": [
- "sg-03ccf232a2bf0f4ea"
], - "tags": [
- {
- "tagKey": "env",
- "tagValue": "staging"
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec"
}
}
Launch nodes in Virtual Node Group.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (Ocean AWS Virtual Node Group Launch Request) Object specifying the details for the launch request. | ||
|
{- "launchRequest": {
- "amount": 5
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/k8s/launchSpec/ols-12345abc/launchNodes",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "launchSpecId": "ols-f73821bc",
- "newInstances": [
- {
- "instanceId": "i-08d53d2a1dcede08f",
- "availabilityZone": "us-west-2b",
- "instanceType": "c3.xlarge",
- "lifeCycle": "spot"
}
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:launchSpec:launchNodes"
}
}
Creates an Ocean extended resource definition entity.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (Ocean Extended Resource Definition) The Ocean extended resource definition. | ||||
|
{- "extendedResourceDefinition": {
- "name": "example.com/name",
- "mapping": {
- "c3.large": "2Ki",
- "c3.xlarge": "4Ki",
- "c3.2xlarge": "8Mi"
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/k8s/extendedResourceDefinition",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "erd-123abc",
- "name": "example.com/name",
- "mapping": {
- "c3.large": "2Ki",
- "c3.xlarge": "4Ki",
- "c3.2xlarge": "8Mi"
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:k8s:extendedResourceDefinition"
}
}
List the configurations for all Ocean extended resource definitions in the specified account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/k8s/extendedResourceDefinition",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "erd-123abc",
- "name": "example.com/name",
- "mapping": {
- "c3.large": "2Ki",
- "c3.xlarge": "4Ki",
- "c3.2xlarge": "8Mi"
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:k8s:extendedResourceDefinition"
}
}
Get the configurations for a specified Ocean extended resource definition.
oceanExtendedResourceDefinitionId required | string Example: erd-12345abc Identifier of the Ocean extended resource definition. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/k8s/extendedResourceDefinition/erd-12345abc",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "erd-123abc",
- "name": "example.com/name",
- "mapping": {
- "c3.large": "2Ki",
- "c3.xlarge": "4Ki",
- "c3.2xlarge": "8Mi"
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:k8s:extendedResourceDefinition"
}
}
Only the mapping parameter is updatable for extended resource definition.
oceanExtendedResourceDefinitionId required | string Example: erd-12345abc Identifier of the Ocean extended resource definition. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (Ocean Extended Resource Definition) The Ocean extended resource definition. | ||||
|
{- "extendedResourceDefinition": {
- "name": "example.com/name",
- "mapping": {
- "c3.large": "2Ki",
- "c3.xlarge": "4Ki",
- "c3.2xlarge": "8Mi"
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/k8s/extendedResourceDefinition/erd-12345abc",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "erd-123abc",
- "name": "example.com/name",
- "mapping": {
- "c3.large": "2Ki",
- "c3.xlarge": "4Ki",
- "c3.2xlarge": "8Mi"
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:k8s:extendedResourceDefinition"
}
}
Delete a specified Ocean extended resource definition.
oceanExtendedResourceDefinitionId required | string Example: erd-12345abc Identifier of the Ocean extended resource definition. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/k8s/extendedResourceDefinition/erd-12345abc",
- "method": "DELETE",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Get information about nodes which can be migrated into Ocean.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
shouldFetchPods | boolean Example: shouldFetchPods=true Should fetch data about running pods for each node. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "ocean/aws/k8s/cluster/o-abcd1234/migration/discovery",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "instances": [
- {
- "k8sNodeName": "ip-111-11-11-111.us-west-1.compute.internal",
- "asgName": "asg-name",
- "instanceId": "i-asdfjk3989",
- "launchSpecId": "ols-1234ascv",
- "runningPods": "6"
}
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:cluster:migration:discovery"
}
}
Create a migration for a given existing instances.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object Migration update configuration. | ||||||||||
|
{- "migration": {
- "instanceIds": [
- "i-a12345",
- "i-b12345"
], - "shouldTerminateDrainedNodes": true,
- "shouldEvictStandAlonePods": true,
- "forcePodEvictionOnPdbFailure": true,
- "batchSizePercentage": 50
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "ocean/aws/k8s/cluster/o-1234567/migration",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "owm-6e3819ae"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:cluster:migration"
}
}
Get summary of migrations history for an Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "ocean/aws/k8s/cluster/o-1234567/migration",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "Id": "owm-1234567",
- "state": "FINISHED",
- "createdAt": "2021-10-1T05:51:06.000Z",
- "completedAt": "2021-10-1T05:51:06.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:cluster:migration"
}
}
Get Migration full info and status for an Ocean cluster.
migrationId required | string Example: owm-6e3819ae The migration identifier of a specific migration. |
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "ocean/aws/k8s/cluster/o-abcd1234/migration/owm-abcd1234",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "Id": "owm-1234567",
- "oceanId": "o-abcd1234",
- "status": "FINISHED",
- "newInstances": [
- {
- "instanceId": "i-asdfjk3989",
- "k8sNodeName": "ip-111-11-11-111.us-west-1.compute.internal",
- "asgName": "asg-name",
- "state": "RUNNING",
- "podDetails": [
- {
- "id": "abc123-abc123-abc123-abc123",
- "name": "podName",
- "kind": "STAND_ALONE_POD"
}
], - "runningPods": "6"
}
], - "oldInstances": [
- {
- "instanceId": "i-asdfjk3989",
- "k8sNodeName": "ip-111-11-11-111.us-west-1.compute.internal",
- "asgName": "asg-name",
- "state": "RUNNING",
- "podDetails": [
- {
- "id": "abc123-abc123-abc123-abc123",
- "name": "podName",
- "kind": "STAND_ALONE_POD"
}
], - "runningPods": "6"
}
], - "unscheduledPodIds": "o-abcd1234",
- "newUnscheduledPodIds": "o-abcd1234",
- "migrationConfig": {
- "shouldTerminateDrainedNodes": true,
- "shouldEvictStandAlonePods": true
}, - "createdAt": "2021-10-1T05:51:06.000Z",
- "erroredAt": "2021-10-1T05:51:06.000Z",
- "stoppedAt": "2021-10-1T05:51:06.000Z",
- "completedAt": "2021-10-1T05:51:06.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:cluster:migration"
}
}
Stop an ongoing Workload Migration.
migrationId required | string Example: owm-6e3819ae The migration identifier of a specific migration. |
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object Migration update configuration. | ||||
|
{- "migration": {
- "shouldTerminateDrainedNodes": true,
- "state": "STOPPED"
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "ocean/aws/k8s/cluster/o-1234567/migration/owm-abc1234",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "owm-6e3819ae",
- "oceanId": "o-12e31234",
- "state": "STOPPED"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:k8s:cluster:migration"
}
}
Ocean - Serverless containers for Amazon Elastic Container Service (ECS)
Get the configurations for all Ocean clusters in the specified account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-12345abc",
- "name": "Ocean::my-elastigroup-name",
- "clusterName": "my-ECS-cluster-name",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 300,
- "resourceLimits": {
- "maxMemoryGib": 1,
- "maxVCpu": 1
}, - "down": {
- "evaluationPeriods": 4,
- "maxScaleDownPercentage": 20
}, - "headroom": {
- "cpuPerUnit": 2048,
- "memoryPerUnit": 3,
- "numOfUnits": 2
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": 20,
- "shouldScaleDownNonServiceTasks": true,
- "enableAutomaticAndManualHeadroom": false
}, - "capacity": {
- "minimum": 1,
- "maximum": 10,
- "target": 5
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 200,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}
}, - "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "instanceTypes": {
- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
]
}, - "launchSpecification": {
- "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "iamInstanceProfile": {
- "arn": "my-arn"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}, - "userData": "Q29udGVudC1UeXBlOiBtdWx0aXBhcnQvbWl4ZWQ7IGJvdW5kYXJ5PSI9PT09PT09PT09PT09PT01MTg5MDY1Mzc3MjIyODk4NDA3PT0iCk1JTUUtVmVyc2lvbjogMS4wCgotLT09PT09PT09PT09PT09PTUxODkwNjUzNzcyMjI4OTg0MDc9PQp",
- "useAsTemplateOnly": false,
- "monitoring": false,
- "ebsOptimized": false,
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
]
}, - "optimizeImages": {
- "shouldOptimizeEcsAmi": "true",
- "performAt": "never",
- "timeWindows": [
- "['Sun:02:00-Sun:12:00', 'Wed:01:01-Fri:02:03']"
]
}
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": false,
- "cronExpression": "string",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs"
}
}
Create a new Ocean ECS cluster in the specified account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (ECS Ocean) | ||||||||||||||||||
|
{- "cluster": {
- "name": "Ocean::my-elastigroup-name",
- "clusterName": "my-ECS-cluster-name",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 300,
- "resourceLimits": {
- "maxMemoryGib": 1,
- "maxVCpu": 1
}, - "down": {
- "evaluationPeriods": 4,
- "maxScaleDownPercentage": 20
}, - "headroom": {
- "cpuPerUnit": 2048,
- "memoryPerUnit": 3,
- "numOfUnits": 2
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": 20,
- "shouldScaleDownNonServiceTasks": true,
- "enableAutomaticAndManualHeadroom": false
}, - "region": "us-east-1",
- "capacity": {
- "minimum": 1,
- "maximum": 10,
- "target": 5
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 200,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}
}, - "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "instanceTypes": {
- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
]
}, - "launchSpecification": {
- "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "iamInstanceProfile": {
- "arn": "my-arn"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}, - "userData": "Q29udGVudC1UeXBlOiBtdWx0aXBhcnQvbWl4ZWQ7IGJvdW5kYXJ5PSI9PT09PT09PT09PT09PT01MTg5MDY1Mzc3MjIyODk4NDA3PT0iCk1JTUUtVmVyc2lvbjogMS4wCgotLT09PT09PT09PT09PT09PTUxODkwNjUzNzcyMjI4OTg0MDc9PQp",
- "useAsTemplateOnly": false,
- "monitoring": false,
- "ebsOptimized": false,
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
]
}, - "optimizeImages": {
- "shouldOptimizeEcsAmi": "true",
- "performAt": "never",
- "timeWindows": [
- "['Sun:02:00-Sun:12:00', 'Wed:01:01-Fri:02:03']"
]
}
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": false,
- "cronExpression": "string",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-12345abc",
- "name": "Ocean::my-elastigroup-name",
- "clusterName": "my-ECS-cluster-name",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 300,
- "resourceLimits": {
- "maxMemoryGib": 1,
- "maxVCpu": 1
}, - "down": {
- "evaluationPeriods": 4,
- "maxScaleDownPercentage": 20
}, - "headroom": {
- "cpuPerUnit": 2048,
- "memoryPerUnit": 3,
- "numOfUnits": 2
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": 20,
- "shouldScaleDownNonServiceTasks": true,
- "enableAutomaticAndManualHeadroom": false
}, - "capacity": {
- "minimum": 1,
- "maximum": 10,
- "target": 5
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 200,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}
}, - "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "instanceTypes": {
- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
]
}, - "launchSpecification": {
- "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "iamInstanceProfile": {
- "arn": "my-arn"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}, - "userData": "Q29udGVudC1UeXBlOiBtdWx0aXBhcnQvbWl4ZWQ7IGJvdW5kYXJ5PSI9PT09PT09PT09PT09PT01MTg5MDY1Mzc3MjIyODk4NDA3PT0iCk1JTUUtVmVyc2lvbjogMS4wCgotLT09PT09PT09PT09PT09PTUxODkwNjUzNzcyMjI4OTg0MDc9PQp",
- "useAsTemplateOnly": false,
- "monitoring": false,
- "ebsOptimized": false,
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
]
}, - "optimizeImages": {
- "shouldOptimizeEcsAmi": "true",
- "performAt": "never",
- "timeWindows": [
- "['Sun:02:00-Sun:12:00', 'Wed:01:01-Fri:02:03']"
]
}
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": false,
- "cronExpression": "string",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs"
}
}
Get the configurations for a specified Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-12345abc",
- "name": "Ocean::my-elastigroup-name",
- "clusterName": "my-ECS-cluster-name",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 300,
- "resourceLimits": {
- "maxMemoryGib": 1,
- "maxVCpu": 1
}, - "down": {
- "evaluationPeriods": 4,
- "maxScaleDownPercentage": 20
}, - "headroom": {
- "cpuPerUnit": 2048,
- "memoryPerUnit": 3,
- "numOfUnits": 2
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": 20,
- "shouldScaleDownNonServiceTasks": true,
- "enableAutomaticAndManualHeadroom": false
}, - "capacity": {
- "minimum": 1,
- "maximum": 10,
- "target": 5
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 200,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}
}, - "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "instanceTypes": {
- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
]
}, - "launchSpecification": {
- "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "iamInstanceProfile": {
- "arn": "my-arn"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}, - "userData": "Q29udGVudC1UeXBlOiBtdWx0aXBhcnQvbWl4ZWQ7IGJvdW5kYXJ5PSI9PT09PT09PT09PT09PT01MTg5MDY1Mzc3MjIyODk4NDA3PT0iCk1JTUUtVmVyc2lvbjogMS4wCgotLT09PT09PT09PT09PT09PTUxODkwNjUzNzcyMjI4OTg0MDc9PQp",
- "useAsTemplateOnly": false,
- "monitoring": false,
- "ebsOptimized": false,
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
]
}, - "optimizeImages": {
- "shouldOptimizeEcsAmi": "true",
- "performAt": "never",
- "timeWindows": [
- "['Sun:02:00-Sun:12:00', 'Wed:01:01-Fri:02:03']"
]
}
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": false,
- "cronExpression": "string",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs"
}
}
All Ocean parameters are updatable, excluding Region and ID. This API supports partial updates, so specific fields can be updated separately.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
autoApplyTags | boolean Default: false Example: autoApplyTags=true Optionally update resource tags on the fly without performing a roll. |
required | object (ECS Ocean) | ||||||||||||||||
|
{- "cluster": {
- "name": "Ocean::my-elastigroup-name",
- "clusterName": "my-ECS-cluster-name",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 300,
- "resourceLimits": {
- "maxMemoryGib": 1,
- "maxVCpu": 1
}, - "down": {
- "evaluationPeriods": 4,
- "maxScaleDownPercentage": 20
}, - "headroom": {
- "cpuPerUnit": 2048,
- "memoryPerUnit": 3,
- "numOfUnits": 2
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": 20,
- "shouldScaleDownNonServiceTasks": true,
- "enableAutomaticAndManualHeadroom": false
}, - "capacity": {
- "minimum": 1,
- "maximum": 10,
- "target": 5
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 200,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}
}, - "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "instanceTypes": {
- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
]
}, - "launchSpecification": {
- "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "iamInstanceProfile": {
- "arn": "my-arn"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}, - "userData": "Q29udGVudC1UeXBlOiBtdWx0aXBhcnQvbWl4ZWQ7IGJvdW5kYXJ5PSI9PT09PT09PT09PT09PT01MTg5MDY1Mzc3MjIyODk4NDA3PT0iCk1JTUUtVmVyc2lvbjogMS4wCgotLT09PT09PT09PT09PT09PTUxODkwNjUzNzcyMjI4OTg0MDc9PQp",
- "useAsTemplateOnly": false,
- "monitoring": false,
- "ebsOptimized": false,
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
]
}, - "optimizeImages": {
- "shouldOptimizeEcsAmi": "true",
- "performAt": "never",
- "timeWindows": [
- "['Sun:02:00-Sun:12:00', 'Wed:01:01-Fri:02:03']"
]
}
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": false,
- "cronExpression": "string",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-12345abc",
- "name": "Ocean::my-elastigroup-name",
- "clusterName": "my-ECS-cluster-name",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 300,
- "resourceLimits": {
- "maxMemoryGib": 1,
- "maxVCpu": 1
}, - "down": {
- "evaluationPeriods": 4,
- "maxScaleDownPercentage": 20
}, - "headroom": {
- "cpuPerUnit": 2048,
- "memoryPerUnit": 3,
- "numOfUnits": 2
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": 20,
- "shouldScaleDownNonServiceTasks": true,
- "enableAutomaticAndManualHeadroom": false
}, - "capacity": {
- "minimum": 1,
- "maximum": 10,
- "target": 5
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 200,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}
}, - "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "instanceTypes": {
- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
]
}, - "launchSpecification": {
- "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "iamInstanceProfile": {
- "arn": "my-arn"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}, - "userData": "Q29udGVudC1UeXBlOiBtdWx0aXBhcnQvbWl4ZWQ7IGJvdW5kYXJ5PSI9PT09PT09PT09PT09PT01MTg5MDY1Mzc3MjIyODk4NDA3PT0iCk1JTUUtVmVyc2lvbjogMS4wCgotLT09PT09PT09PT09PT09PTUxODkwNjUzNzcyMjI4OTg0MDc9PQp",
- "useAsTemplateOnly": false,
- "monitoring": false,
- "ebsOptimized": false,
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
]
}, - "optimizeImages": {
- "shouldOptimizeEcsAmi": "true",
- "performAt": "never",
- "timeWindows": [
- "['Sun:02:00-Sun:12:00', 'Wed:01:01-Fri:02:03']"
]
}
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": false,
- "cronExpression": "string",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs"
}
}
Delete a specified Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Create Ocean cluster object from an existing ECS cluster with at least one container instance to be used as input for create cluster.
Import the configuration from the latest instance id launched with in the cluster (out of the first batch of 100 instances ECS returns).
This route will not register the ECS cluster to Ocean.
EcsClusterName required | string Example: ecsName ECS Cluster name |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
instanceId | string Indicate the container instance id that the configuration will be taken from. This is an optional field |
name | string The name for the new Ocean cluster object. |
region required | string The region that the ECS cluster is running at. |
{- "region": "us-east-1",
- "name": "oceanName",
- "instanceId": "i-123456789abcdefgh"
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/cluster/my-ECS-cluster-name/import",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "name": "my-Ocean-ECS-cluster",
- "clusterName": "my-ECS-cluster-name",
- "region": "us-east-1",
- "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "launchSpecification": {
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "keyPair": "dev-keypair",
- "userData": "userData",
- "iamInstanceProfile": {
- "arn": "my-arn"
}, - "tags": {
- "tagKey": "env",
- "tagValue": "dev"
}, - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}
}
}
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs"
}
}
Get the log of an Ocean Cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
fromDate required | string Beginning date value using either the date format "yyyy-mm-dd; 2016-11-20" or ms "1494751821472". |
limit | integer <= 1000 Default: 500 Example: limit=200 Maximum number of lines to extract in a response. |
resourceId | string Example: resourceId=i-12345678 Filter extracted log entries for a specific resource identifier. Default: Null |
severity | string Default: "ALL" Enum: "ALL" "INFO" "DEBUG" "ERROR" "WARN" Example: severity=INFO Severity of log entries to extract. |
toDate required | string End date value using either the date format "yyyy-mm-dd; 2016-11-20" or ms "1494751821472". |
{- "request": {
- "id": "3213f42e-455e-4801-a185-cd3eb65fac5f",
- "url": "/ocean/aws/ecs/cluster/o-e0a2bd7c/log?fromDate=2020-10-06&toDate=2020-10-08&severity=ALL&limit=500",
- "method": "GET",
- "timestamp": "2020-10-05T16:20:38.579Z"
}, - "response": {
- "status": {
- "code": "200",
- "message": "OK"
}, - "kind": "spotinst:ocean:cluster:log",
- "items": [
- {
- "message": "Instances Terminated - ECS Autoscaler ,Terminated 1, List of instances: [i-0914721d46ebbabb2]",
- "severity": "INFO",
- "createdAt": "2020-10-07T09:51:12.000Z"
}, - {
- "message": "Instances: [i-0914721d46ebbabb2] have been detached. Reason: Auto scale",
- "severity": "INFO",
- "createdAt": "2020-10-07T09:51:11.000Z"
}
], - "count": "2"
}
}
Get right-sizing recommendations for an Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "suggestedMemory": 2,
- "requestedMemory": 100,
- "serviceName": "sg-test",
- "suggestedCpu": 0,
- "requestedCpu": 128
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:cluster:rightSizing:resourceSuggestion"
}
}
Returns all instances types that match the given filters. These instance types will be used if the cluster is configured with these filters.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (InstanceTypesFilters) List of filters. The Instance types that match with all filters compose the Ocean's whitelist parameter. Cannot be configured together with whitelist/blacklist. | ||||||||||||||||||||||||||||||||||||||
|
{- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/cluster/o-abcd1234/instanceTypeFiltersSimulation",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "filteredInstanceTypes": [
- "g5.xlarge",
- "c5.2xlarge",
- "c5ad.2xlarge",
- "c5d.2xlarge",
- "c5a.2xlarge"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:instanceTypesFilters:simulation"
}
}
Return the list of the allowed Ocean cluster instance types.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/cluster/0-12345abc/allowedInstanceTypes",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "instanceTypes": [
- "c3.large",
- "c5.large"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:allowedInstanceTypes"
}
}
Upgrade an Elastigroup with ECS integration into Ocean for ECS cluster.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
groupId required | string Example: groupId=sig-1234abcd The identifier of the Elastigroup to upgrade. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-12345abc",
- "name": "Ocean::my-elastigroup-name",
- "clusterName": "my-ECS-cluster-name",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 300,
- "resourceLimits": {
- "maxMemoryGib": 1,
- "maxVCpu": 1
}, - "down": {
- "evaluationPeriods": 4,
- "maxScaleDownPercentage": 20
}, - "headroom": {
- "cpuPerUnit": 2048,
- "memoryPerUnit": 3,
- "numOfUnits": 2
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": 20,
- "shouldScaleDownNonServiceTasks": true,
- "enableAutomaticAndManualHeadroom": false
}, - "capacity": {
- "minimum": 1,
- "maximum": 10,
- "target": 5
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 200,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}
}, - "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "instanceTypes": {
- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
]
}, - "launchSpecification": {
- "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "iamInstanceProfile": {
- "arn": "my-arn"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}, - "userData": "Q29udGVudC1UeXBlOiBtdWx0aXBhcnQvbWl4ZWQ7IGJvdW5kYXJ5PSI9PT09PT09PT09PT09PT01MTg5MDY1Mzc3MjIyODk4NDA3PT0iCk1JTUUtVmVyc2lvbjogMS4wCgotLT09PT09PT09PT09PT09PTUxODkwNjUzNzcyMjI4OTg0MDc9PQp",
- "useAsTemplateOnly": false,
- "monitoring": false,
- "ebsOptimized": false,
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
]
}, - "optimizeImages": {
- "shouldOptimizeEcsAmi": "true",
- "performAt": "never",
- "timeWindows": [
- "['Sun:02:00-Sun:12:00', 'Wed:01:01-Fri:02:03']"
]
}
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": false,
- "cronExpression": "string",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "s3": {
- "id": "di-123"
}
}
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs"
}
}
Roll an entire Ocean cluster or roll subsets of the cluster by specifying launchSpecIds or instanceIds. Performing this request will start the roll immediately according to defined batches. Note that the first response for a successful request will indicate the start of a roll. In order to check the status of a roll, you can use the GET Roll API using the roll identifier.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object | |||||||
|
{- "roll": {
- "batchSizePercentage": 20,
- "comment": "This is why I rolled my cluster.",
- "batchMinHealthyPercentage": 100
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-1234abcd",
- "scope": "Cluster",
- "currentBatch": 1,
- "numOfBatches": 2,
- "progress": {
- "unit": "percentage",
- "value": 10,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceId": "i-003a0281a24c01a20",
- "status": "REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a21",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a22",
- "status": "COULD_NOT_BE_REPLACED"
}
]
}
}, - "oceanId": "o-abcd1234",
- "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z",
- "status": "IN_PROGRESS",
- "comment": "This is why I rolled my cluster.",
- "batchMinHealthyPercentage": 100,
- "instanceIds": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:cluster:roll"
}
}
List rolls of an Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-1234abcd",
- "scope": "Cluster",
- "currentBatch": 1,
- "numOfBatches": 2,
- "progress": {
- "unit": "percentage",
- "value": 10,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceId": "i-003a0281a24c01a20",
- "status": "REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a21",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a22",
- "status": "COULD_NOT_BE_REPLACED"
}
]
}
}, - "oceanId": "o-abcd1234",
- "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z",
- "status": "IN_PROGRESS",
- "comment": "This is why I rolled my cluster.",
- "batchMinHealthyPercentage": 100,
- "instanceIds": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:cluster:roll"
}
}
Update a roll of an Ocean cluster. Performing the request will stop the next batch in a roll.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
ROLL_ID required | string Example: scr-12345abc Ocean Cluster Roll identifier |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object Sets the status of the roll. | |||
|
{- "roll": {
- "status": "STOPPED"
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-1234abcd",
- "scope": "Cluster",
- "currentBatch": 1,
- "numOfBatches": 2,
- "progress": {
- "unit": "percentage",
- "value": 10,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceId": "i-003a0281a24c01a20",
- "status": "REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a21",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a22",
- "status": "COULD_NOT_BE_REPLACED"
}
]
}
}, - "oceanId": "o-abcd1234",
- "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z",
- "status": "IN_PROGRESS",
- "comment": "This is why I rolled my cluster.",
- "batchMinHealthyPercentage": 100,
- "instanceIds": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:cluster:roll"
}
}
Get status for roll of an Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
ROLL_ID required | string Example: scr-12345abc Ocean Cluster Roll identifier |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-1234abcd",
- "scope": "Cluster",
- "currentBatch": 1,
- "numOfBatches": 2,
- "progress": {
- "unit": "percentage",
- "value": 10,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceId": "i-003a0281a24c01a20",
- "status": "REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a21",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceId": "i-003a0281a24c01a22",
- "status": "COULD_NOT_BE_REPLACED"
}
]
}
}, - "oceanId": "o-abcd1234",
- "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z",
- "status": "IN_PROGRESS",
- "comment": "This is why I rolled my cluster.",
- "batchMinHealthyPercentage": 100,
- "instanceIds": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:cluster:roll"
}
}
Get container instances data of an Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
instanceId | string Example: instanceId=i-123 Get a specific container instance ec2 instance id. |
launchSpecId | string Example: launchSpecId=ols-123abc Ocean cluster Virtual Node Group identifier. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/cluster/o-12345abc/containerInstances",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "instanceId": "i-123",
- "instanceType": "c3.large",
- "availabilityZone": "us-west-2b",
- "launchSpecId": "ols-123",
- "launchSpecName": "dev-launchSpec",
- "lifeCycle": "Spot",
- "publicIp": "1.2.3.4",
- "workloadRequestedCpuUnit": 1320,
- "workloadRequestedMemoryInMiB": 500,
- "workloadRequestedGpu": 1,
- "headroomRequestedCpuUnit": 1320,
- "headroomRequestedMemoryInMiB": 512,
- "headroomRequestedGpu": 1,
- "registeredCpuUnit": 2000,
- "registeredMemoryInMiB": 3646.1,
- "registeredGpu": 1,
- "containerInstanceId": "abcdefg",
- "registrationStatus": "Registered",
- "createdAt": "2021-10-1T05:51:06.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:containerInstances"
}
}
Detach instances from your Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
instancesToDetach required | Array of strings Array of instance identifiers to be detached. |
shouldDecrementTargetCapacity | boolean Determines whether the Ocean cluster's target capacity should be decremented. |
shouldTerminateInstances | boolean Determines whether the detached EC2 instances should be terminated or not. |
{- "instancesToDetach": [
- "i-0003a99ffb566f039",
- "i-0567a99ffb566f765"
], - "shouldTerminateInstances": true,
- "shouldDecrementTargetCapacity": false
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/cluster/o-abcd1234/detachInstances",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Create a new Ocean ECS virtual node group in the specified account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (oceanClusterLaunchSpec-create) AWS Cluster Virtual Node Group (VNG). | ||||||||||||||||||||||||||||||||||||
|
{- "launchSpec": {
- "oceanId": "o-1234abcd",
- "name": "mySpecLauncher",
- "imageId": "img2",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dXNlcmJhc2g2NGVuY29kZWQ=",
- "securityGroupIds": [
- "sg1, sg3"
], - "instanceTypes": [
- "c3.2xlarge, c4.2xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "subnetIds": [
- "subnet-01234566789abcdef, subnet-9876543210ghijkl"
], - "iamInstanceProfile": [
- "arn:aws:iam::123456789123:instance-profile"
], - "attributes": [
- {
- "key": "key1",
- "value": "value1"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "restrictScaleDown": false,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}
}
]
}, - "strategy": {
- "spotPercentage": 70
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/launchSpec",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ols-1234abcd",
- "oceanId": "o-1234abcd",
- "name": "mySpecLauncher",
- "imageId": "img2",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dXNlcmJhc2g2NGVuY29kZWQ=",
- "securityGroupIds": [
- "sg1, sg3"
], - "instanceTypes": [
- "c3.2xlarge, c4.2xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "subnetIds": [
- "subnet-01234566789abcdef, subnet-9876543210ghijkl"
], - "iamInstanceProfile": [
- "arn:aws:iam::123456789123:instance-profile"
], - "attributes": [
- {
- "key": "key1",
- "value": "value1"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "restrictScaleDown": false,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}
}
]
}, - "strategy": {
- "spotPercentage": 70
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:launchSpec"
}
}
Get all the custom VNGs for all Ocean clusters in the specified account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
oceanId | string Example: oceanId=o-12345abc Identifier of the Ocean cluster. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/launchSpec",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ols-1234abcd",
- "oceanId": "o-1234abcd",
- "name": "mySpecLauncher",
- "imageId": "img2",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dXNlcmJhc2g2NGVuY29kZWQ=",
- "securityGroupIds": [
- "sg1, sg3"
], - "instanceTypes": [
- "c3.2xlarge, c4.2xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "subnetIds": [
- "subnet-01234566789abcdef, subnet-9876543210ghijkl"
], - "iamInstanceProfile": [
- "arn:aws:iam::123456789123:instance-profile"
], - "attributes": [
- {
- "key": "key1",
- "value": "value1"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "restrictScaleDown": false,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}
}
]
}, - "strategy": {
- "spotPercentage": 70
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:launchSpec"
}
}
Get a specific custom launch configuration for an Ocean cluster in the specified account.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/launchSpec/ols-12345abc",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ols-1234abcd",
- "oceanId": "o-1234abcd",
- "name": "mySpecLauncher",
- "imageId": "img2",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dXNlcmJhc2g2NGVuY29kZWQ=",
- "securityGroupIds": [
- "sg1, sg3"
], - "instanceTypes": [
- "c3.2xlarge, c4.2xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "subnetIds": [
- "subnet-01234566789abcdef, subnet-9876543210ghijkl"
], - "iamInstanceProfile": [
- "arn:aws:iam::123456789123:instance-profile"
], - "attributes": [
- {
- "key": "key1",
- "value": "value1"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "restrictScaleDown": false,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}
}
]
}, - "strategy": {
- "spotPercentage": 70
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:launchSpec"
}
}
Delete a specified virtual node group in an Ocean cluster.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
deleteContainerInstances | boolean Default: false Example: deleteContainerInstances=true When set to "true", all instances belonging to the deleted VNG will be drained, detached, and terminated. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/launchSpec/ols-12345abc",
- "method": "DELETE",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Update a specified virtual node group in an Ocean cluster.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
autoApplyTags | boolean Default: false Example: autoApplyTags=true Optionally update resource tags on the fly without performing a roll. |
required | object (oceanClusterLaunchSpec-update) AWS Cluster Virtual Node Group (VNG). | ||||||||||||||||||||||||||||||||||
|
{- "launchSpec": {
- "name": "mySpecLauncher",
- "imageId": "img2",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dXNlcmJhc2g2NGVuY29kZWQ=",
- "securityGroupIds": [
- "sg1, sg3"
], - "instanceTypes": [
- "c3.2xlarge, c4.2xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "subnetIds": [
- "subnet-01234566789abcdef, subnet-9876543210ghijkl"
], - "iamInstanceProfile": [
- "arn:aws:iam::123456789123:instance-profile"
], - "attributes": [
- {
- "key": "key1",
- "value": "value1"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "restrictScaleDown": false,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}
}
]
}, - "strategy": {
- "spotPercentage": 70
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/launchSpec/ols-12345abc",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "ols-1234abcd",
- "name": "mySpecLauncher",
- "imageId": "img2",
- "images": [
- {
- "id": "ami-ID"
}
], - "userData": "dXNlcmJhc2g2NGVuY29kZWQ=",
- "securityGroupIds": [
- "sg1, sg3"
], - "instanceTypes": [
- "c3.2xlarge, c4.2xlarge"
], - "preferredSpotTypes": [
- "c3.2xlarge",
- "c4.2xlarge"
], - "subnetIds": [
- "subnet-01234566789abcdef, subnet-9876543210ghijkl"
], - "iamInstanceProfile": [
- "arn:aws:iam::123456789123:instance-profile"
], - "attributes": [
- {
- "key": "key1",
- "value": "value1"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}, - "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
], - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "restrictScaleDown": false,
- "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "numOfUnits": 2
}
]
}
}
]
}, - "strategy": {
- "spotPercentage": 70
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:launchSpec"
}
}
Import a Fargate service into an existing Ocean ECS cluster. Upon Fargate service import, Spot clones the selected Fargate services and runs them with the same VPC & Subnet settings on EC2 spot Instances. Ocean will automatically and seamlessly predict and replace spot instances before they are interrupted, ensuring the uptime of the cluster and providing cost-savings of up to 90% over Fargate-enabled ECS clusters.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
services | Array of strings List of Fargate services by their names. Must contain at least one service. |
simpleNewServiceNames | boolean Default: false Flag to align imported service names in the following format: sfm_ |
{- "services": [
- "service_1",
- "service_2"
], - "simpleNewServiceNames": false
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "efm-d235b4d8",
- "oceanId": "o-fgdfgdf",
- "state": "STARTING",
- "config": {
- "services": [
- "service_1",
- "service_2"
]
}, - "simpleNewServiceNames": false
}
], - "count": 1,
- "kind": "string"
}
}
Get existing Fargate services in the ECS cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "ecsClusterName": "EcsTestCluster",
- "ecsClusterRegion": "us-east-2",
- "serviceNames": [
- [
- "test_with_1",
- "test_without"
]
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:fargateMigration:serviceDiscovery"
}
}
Get the status of a Fargate service import.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "ecsClusterName": "EcsTestCluster",
- "ecsClusterRegion": "us-east-2",
- "state": "FINISHED",
- "importedServices": [
- "test_with_1"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:fargateMigration:status"
}
}
This API copies the configuration from a Fargate service into the corresponding fields of an Ocean object. (This process is commonly referred to as importing.) The API returns an Ocean object that is suitable for use in the Create API to create a new Ocean cluster based on your Fargate configuration. If you are migrating a Fargate service that has tags, you must run the Opt In procedure on your Amazon account or IAM role. This is required in order to obtain the necessary Amazon Resource Name (ARN) and resource identifier format for your ECS tasks, container instances, and services. For more information about the required ARN and the Opt In procedure, see the following pages:
The API requires one of the following permissions to be defined in Spot -
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
ecsClusterName required | string Name of the cluster in ECS. |
keyPair | string Specify a key pair to attach to the services. |
oceanClusterName required | string Name of the cluster in new Ocean object. |
region required | string Name of the AWS region the ECS cluster is in. |
services required | Array of strings[ items ] Name of the ECS Fargate service to be imported. |
Array of objects Set tags for the service. Items should be unique. |
{- "oceanClusterName": "fargate-import-ocean",
- "ecsClusterName": "fargateTestCluster",
- "region": "us-west-1",
- "services": [
- [
- "service_2"
]
], - "keyPair": "spot-prod",
- "tags": [
- {
- "tagKey": "env",
- "tagValue": "prod"
}
]
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "string",
- "method": "string",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "name": "Ocean::my-elastigroup-name",
- "clusterName": "my-ECS-cluster-name",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 300,
- "resourceLimits": {
- "maxMemoryGib": 1,
- "maxVCpu": 1
}, - "down": {
- "evaluationPeriods": 4,
- "maxScaleDownPercentage": 20
}, - "headroom": {
- "cpuPerUnit": 2048,
- "memoryPerUnit": 3,
- "numOfUnits": 2
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": 20,
- "shouldScaleDownNonServiceTasks": true,
- "enableAutomaticAndManualHeadroom": false
}, - "region": "us-east-1",
- "capacity": {
- "minimum": 1,
- "maximum": 10,
- "target": 5
}, - "strategy": {
- "utilizeReservedInstances": true,
- "fallbackToOd": true,
- "spotPercentage": 100,
- "drainingTimeout": 200,
- "utilizeCommitments": false,
- "clusterOrientation": {
- "availabilityVsCost": "balanced"
}
}, - "compute": {
- "subnetIds": [
- "subnet-1234abcd"
], - "instanceTypes": {
- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "minGpu": 0,
- "maxGpu": 4,
- "includeFamilies": [
- "c5*",
- "g5"
], - "excludeFamilies": [
- "t2",
- "R4*"
], - "excludeMetal": true,
- "isEnaSupported": true,
- "architectures": [
- "i386",
- "x86_64"
], - "virtualizationTypes": [
- "hvm"
], - "categories": [
- "Accelerated_computing",
- "Compute_optimized"
], - "minEnis": 2,
- "diskTypes": [
- "NVMe",
- "EBS"
], - "hypervisor": [
- "nitro"
], - "rootDeviceTypes": [
- "ebs"
], - "minNetworkPerformance": 2,
- "maxNetworkPerformance": 20
}, - "whitelist": [
- "c4.xlarge",
- "c4.2xlarge",
- "c4.4xlarge",
- "c4.8xlarge"
], - "blacklist": [
- "r5.large",
- "r5.xlarge"
]
}, - "launchSpecification": {
- "associatePublicIpAddress": false,
- "associateIpv6Address": false,
- "imageId": "ami-123456789abcdefgh",
- "securityGroupIds": [
- "sg-abcdefgh123456789"
], - "iamInstanceProfile": {
- "arn": "my-arn"
}, - "blockDeviceMappings": [
- {
- "deviceName": "/dev/xvda",
- "ebs": {
- "throughput": 125,
- "deleteOnTermination": false,
- "encrypted": false,
- "iops": 1,
- "kmsKeyId": "alias/aws/ebs",
- "snapshotId": "snap-abcdefghi111110",
- "volumeType": "gp2",
- "volumeSize": 0,
- "dynamicVolumeSize": {
- "baseSize": 50,
- "resource": "CPU",
- "sizePerResourceUnit": 20
}
}
}
], - "instanceMetadataOptions": {
- "httpTokens": "optional",
- "httpPutResponseHopLimit": 12,
- "httpEndpoint": "disabled",
- "instanceMetadataTags": "Enabled"
}, - "userData": "Q29udGVudC1UeXBlOiBtdWx0aXBhcnQvbWl4ZWQ7IGJvdW5kYXJ5PSI9PT09PT09PT09PT09PT01MTg5MDY1Mzc3MjIyODk4NDA3PT0iCk1JTUUtVmVyc2lvbjogMS4wCgotLT09PT09PT09PT09PT09PTUxODkwNjUzNzcyMjI4OTg0MDc9PQp",
- "useAsTemplateOnly": false,
- "monitoring": false,
- "ebsOptimized": false,
- "tags": [
- {
- "tagKey": "Creator",
- "tagValue": "John Doe"
}
]
}, - "optimizeImages": {
- "shouldOptimizeEcsAmi": "true",
- "performAt": "never",
- "timeWindows": [
- "['Sun:02:00-Sun:12:00', 'Wed:01:01-Fri:02:03']"
]
}
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": false,
- "cronExpression": "string",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100
}
}
}
], - "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}
}
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs"
}
}
Provides Ecs cluster resource usage and costs over a time interval which can be grouped and/or filtered by AWS tags,
for example - application name (webapp, backend), environment (production, staging), version etc.
The response will contain a breakdown of the cluster resource costs($) in terms of compute (CPU, memory), storage (block, file, rootVolume).
The response will group the cluster usage costs based on the preselected default of Ecs Group Type which is composed of Service, Headroom, Custom Object,
Idle and Standalone, or user selected AWS tags.
Within the default grouping, costs are broken down for the Service group, and for tag grouping the costs will be broken up by tag value.
Time Rounding Down: The CostAnalysis API applies rounding down to the hours provided during the call.
For example, the value 1707004799099 (In GMT) representing Saturday, February 3, 2024, 23:59:59.099 is rounded down to Saturday, February 3, 2024, 23:00:00.000, resulting in the omission of one hour of cost.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
endTime required | string End date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
object Describe how to filter the costs. Optional field. Can only be used if grouping by tags. | |
groupBy | string The parameter we want to group the costs by, default is grouping by ECS group types. Only a tag key can be passed in. |
startTime required | string Beginning date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
{- "startTime": 1675209600000,
- "endTime": 1675216800000,
- "groupBy": "env",
- "filter": {
- "conditions": {
- "anyMatch": [
- {
- "allMatch": [
- {
- "key": "env",
- "operator": "equals",
- "value": "dev"
}, - {
- "key": "app",
- "operator": "exists"
}
]
}, - {
- "allMatch": [
- {
- "key": "team",
- "operator": "exists"
}
]
}
]
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/cluster/o-abcd1234/aggregatedCosts",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "totalForDuration": {
- "startTime": "2023-02-01T12:00:00.745Z",
- "endTime": "2023-02-01T02:00:00.745Z",
- "summary": {
- "total": 20000,
- "compute": {
- "total": 12000,
- "services": {
- "total": 12000
}
}, - "storage": {
- "total": 8000,
- "block": {
- "total": 6000,
- "ebsPv": {
- "total": 4000
}, - "nonPv": {
- "total": 2000
}
}, - "file": {
- "total": 2000,
- "efsPv": {
- "total": 2000
}
}
}
}, - "detailedCostsByTime": [
- {
- "startTime": "2023-02-01T12:00:00.745Z",
- "endTime": "2023-02-01T01:00:00.745Z",
- "summary": {
- "total": 10000,
- "compute": {
- "total": 6000
}, - "storage": {
- "total": 4000,
- "block": {
- "total": 3000,
- "ebsPv": {
- "total": 2000
}, - "nonPv": {
- "total": 1000
}
}, - "file": {
- "total": 1000,
- "efsPv": {
- "total": 1000
}
}
}
}, - "groupedBy": "env",
- "aggregations": {
- "dev": {
- "summary": {
- "total": 5000,
- "compute": {
- "total": 3000
}, - "storage": {
- "total": 2000,
- "block": {
- "total": 1500,
- "ebsPv": {
- "total": 1000
}, - "nonPv": {
- "total": 500
}
}, - "file": {
- "total": 500,
- "efsPv": {
- "total": 500
}
}
}
}, - "services": [
- {
- "name": "service-1",
- "total": 5000,
- "compute": {
- "total": 3000
}, - "storage": {
- "total": 2000,
- "block": {
- "total": 1500,
- "ebsPv": {
- "total": 1000
}, - "nonPv": {
- "total": 500
}
}, - "file": {
- "total": 500,
- "efsPv": {
- "total": 500
}
}
}
}
]
}, - "prod": {
- "summary": {
- "total": 5000,
- "compute": {
- "total": 3000
}, - "storage": {
- "total": 2000,
- "block": {
- "total": 1500,
- "ebsPv": {
- "total": 1000
}, - "nonPv": {
- "total": 500
}
}, - "file": {
- "total": 500,
- "efsPv": {
- "total": 500
}
}
}
}, - "services": [
- {
- "name": "service-2",
- "total": 5000,
- "compute": {
- "total": 3000
}, - "storage": {
- "total": 2000,
- "block": {
- "total": 1500,
- "ebsPv": {
- "total": 1000
}, - "nonPv": {
- "total": 500
}
}, - "file": {
- "total": 500,
- "efsPv": {
- "total": 500
}
}
}
}
]
}
}
}, - {
- "startTime": "2023-02-01T01:00:00.745Z",
- "endTime": "2023-02-01T02:00:00.745Z",
- "summary": {
- "total": 10000,
- "compute": {
- "total": 6000
}, - "storage": {
- "total": 4000,
- "block": {
- "total": 3000,
- "ebsPv": {
- "total": 2000
}, - "nonPv": {
- "total": 1000
}
}, - "file": {
- "total": 1000,
- "efsPv": {
- "total": 1000
}
}
}
}, - "groupedBy": "env",
- "aggregations": {
- "dev": {
- "summary": {
- "total": 5000,
- "compute": {
- "total": 3000
}, - "storage": {
- "total": 2000,
- "block": {
- "total": 1500,
- "ebsPv": {
- "total": 1000
}, - "nonPv": {
- "total": 500
}
}, - "file": {
- "total": 500,
- "efsPv": {
- "total": 500
}
}
}
}, - "services": [
- {
- "name": "service-1",
- "total": 5000,
- "compute": {
- "total": 3000
}, - "storage": {
- "total": 2000,
- "block": {
- "total": 1500,
- "ebsPv": {
- "total": 1000
}, - "nonPv": {
- "total": 500
}
}, - "file": {
- "total": 500,
- "efsPv": {
- "total": 500
}
}
}
}
]
}, - "prod": {
- "summary": {
- "total": 5000,
- "compute": {
- "total": 3000
}, - "storage": {
- "total": 2000,
- "block": {
- "total": 1500,
- "ebsPv": {
- "total": 1000
}, - "nonPv": {
- "total": 500
}
}, - "file": {
- "total": 500,
- "efsPv": {
- "total": 500
}
}
}
}, - "services": [
- {
- "name": "service-2",
- "total": 5000,
- "compute": {
- "total": 3000
}, - "storage": {
- "total": 2000,
- "block": {
- "total": 1500,
- "ebsPv": {
- "total": 1000
}, - "nonPv": {
- "total": 500
}
}, - "file": {
- "total": 500,
- "efsPv": {
- "total": 500
}
}
}
}
]
}
}
}
]
}
}
], - "count": 1,
- "kind": "ocean:ecs:cluster:aggregatedCosts:detailed"
}
}
Describes ECS cluster costs in a time range.
The response will provide the distribution of the costs per cluster.
Deprecated API: This API is no longer supported. As an alternative you may use the "Get Ecs Cluster Aggregated Detailed Costs" API.
clusterName required | string Example: ocean.ecs The name of the ECS cluster, as set in the Ocean cluster configuration under the "clusterName" field. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
fromDate required | string Beginning date value using either the date format "yyyy-mm-dd; 2016-11-20" or ms "1494751821472". |
region required | string Example: region=us-east-1 Region name. |
toDate required | string End date value using either the date format "yyyy-mm-dd; 2016-11-20" or ms "1494751821472". |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/mcs/ecs/cluster/my-cluster-identifier/costs",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "totalCost": 279.9907,
- "headroomCost": 279.9907,
- "standAloneTasksCost": 0,
- "ecsGroups": [
- {
- "name": "default",
- "cost": 18.00862,
- "type": "SERVICE"
}
]
}
], - "count": 1,
- "kind": "string"
}
}
Launch container instances in virtual node group.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (Ocean ECS VNG Launch Request) | ||
|
{- "launchRequest": {
- "amount": 5
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/aws/ecs/launchSpec/ols-12345abc/launchContainerInstances",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "newInstances": [
- {
- "instanceId": "i-08d53d2a1dcede08f",
- "availabilityZone": "us-west-2b",
- "instanceType": "c3.xlarge",
- "lifeCycle": "spot"
}
]
}
], - "count": 1,
- "kind": "spotinst:ocean:aws:ecs:launchSpec:launchContainerInstances",
- "launchSpecId": "ols-f73821bc"
}
}
Get the heartbeat status of the Ocean Controller for the cluster.
The response returns the heartbeat status and the last heartbeat timestamp.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/k8s/cluster/o-e0a2bd7c/controllerHeartbeat",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "status": "ACTIVE",
- "lastHeartbeat": "2019-11-24T14:33:00.746Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:k8s:cluster:controllerHeartbeat"
}
}
The Ocean Controller is used to monitor the cluster resources and report back to Ocean.| To install the Ocean Controller, complete and run the following script on a machine with the kubectl command line tool installed and configured:
#!/usr/bin/env bash
curl -fsSL http://spotinst-public.s3.amazonaws.com/integrations/kubernetes/cluster-controller/scripts/init.sh | \
SPOTINST_TOKEN=<ENTER YOUR TOKEN HERE> \
SPOTINST_ACCOUNT=<ENTER YOUR SPOTINST ACCOUNT ID HERE> \
SPOTINST_CLUSTER_IDENTIFIER=<ENTER YOUR CLUSTER IDENTIFIER HERE> \
bash
You may need Kubernetes admin privileges for this script to work. To grant yourself admin privileges, run the following command:
kubectl create clusterrolebinding <clusterName> --clusterrole=cluster-admin --user=<userEmail>
For more information, refer to our controller installation guides. You can install with Helm, Kubectl or Terraform. For more about Ocean and the Ocean Controller, see the documentation here.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object The specification of the Ocean cluster. | ||||||||||||||||||||
|
{- "cluster": {
- "name": "test",
- "controllerClusterId": "test-123124",
- "gke": {
- "clusterName": "test-cluster",
- "masterLocation": "us-central1-a"
}, - "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVcpu": 750
}, - "down": {
- "evaluationPeriods": 3,
- "maxScaleDownPercentage": 30,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headRoom": {
- "cpuPerUnit": 0,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnit": 0
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true
}, - "autoUpdate": {
- "isEnabled": true
}, - "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "strategy": {
- "drainingTimeout": 60,
- "provisioningModel": "SPOT",
- "scalingOrientation": "COST",
- "preemptiblePercentage": 100,
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "scheduling": {
- "shutdownHours": {
- "isEnabled": true,
- "timeWindows": [
- [
- "Fri:15:30-Wed:14:30",
- "Wed:15:30-Thu:18:30"
]
]
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
]
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "gce.io/*",
- "docker.*"
]
]
}
}, - "compute": {
- "networkInterfaces": {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}, - "aliasIpRanges": {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
}, - "backendServices": {
- "backendServiceName": "test-global-tcp",
- "locationType": "regional",
- "scheme": "EXTERNAL",
- "namedPorts": {
- "name": "https",
- "ports": [
- 443,
- 8443
]
}
}, - "subnetName": "default",
- "availabilityZones": [
- "us-west1-a"
], - "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
], - "blacklist": [
- "n2d-highcpu-96"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
]
}, - "launchSpecification": {
- "metadata": {
- "key": "example_key1",
- "value": "exmample_value1"
}, - "tags": [
- "gke-cluster-name-12345-node"
], - "ipForwarding": true,
- "minCpuPlatform": "Intel Sandy Bridge",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "labels": [
- {
- "key": "spotinst-gke-original-node-pool",
- "value": "test-native-vpc__default-pool"
}
], - "rootVolumeSizeInGb": 100,
- "rootVolumeType": "pd-standard",
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "useAsTemplateOnly": false
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-abcd1234",
- "name": "test",
- "controllerClusterId": "test-123124",
- "gke": {
- "clusterName": "test-cluster",
- "masterLocation": "us-central1-a"
}, - "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVcpu": 750
}, - "down": {
- "evaluationPeriods": 3,
- "maxScaleDownPercentage": 30,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headRoom": {
- "cpuPerUnit": 0,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnit": 0
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true
}, - "autoUpdate": {
- "isEnabled": true
}, - "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "strategy": {
- "drainingTimeout": 60,
- "provisioningModel": "SPOT",
- "scalingOrientation": "COST",
- "preemptiblePercentage": 100,
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "scheduling": {
- "shutdownHours": {
- "isEnabled": true,
- "timeWindows": [
- [
- "Fri:15:30-Wed:14:30",
- "Wed:15:30-Thu:18:30"
]
]
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
]
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "gce.io/*",
- "docker.*"
]
]
}
}, - "compute": {
- "networkInterfaces": {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}, - "aliasIpRanges": {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
}, - "backendServices": {
- "backendServiceName": "test-global-tcp",
- "locationType": "regional",
- "scheme": "EXTERNAL",
- "namedPorts": {
- "name": "https",
- "ports": [
- 443,
- 8443
]
}
}, - "subnetName": "default",
- "availabilityZones": [
- "us-west1-a"
], - "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
], - "blacklist": [
- "n2d-highcpu-96"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
]
}, - "launchSpecification": {
- "metadata": {
- "key": "example_key1",
- "value": "exmample_value1"
}, - "tags": [
- "gke-cluster-name-12345-node"
], - "ipForwarding": true,
- "minCpuPlatform": "Intel Sandy Bridge",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "labels": [
- {
- "key": "spotinst-gke-original-node-pool",
- "value": "test-native-vpc__default-pool"
}
], - "rootVolumeSizeInGb": 100,
- "rootVolumeType": "pd-standard",
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "useAsTemplateOnly": false
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s"
}
}
List the configurations for all Ocean clusters in the specified account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-abcd1234",
- "name": "test",
- "controllerClusterId": "test-123124",
- "gke": {
- "clusterName": "test-cluster",
- "masterLocation": "us-central1-a"
}, - "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVcpu": 750
}, - "down": {
- "evaluationPeriods": 3,
- "maxScaleDownPercentage": 30,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headRoom": {
- "cpuPerUnit": 0,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnit": 0
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true
}, - "autoUpdate": {
- "isEnabled": true
}, - "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "strategy": {
- "drainingTimeout": 60,
- "provisioningModel": "SPOT",
- "scalingOrientation": "COST",
- "preemptiblePercentage": 100,
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "scheduling": {
- "shutdownHours": {
- "isEnabled": true,
- "timeWindows": [
- [
- "Fri:15:30-Wed:14:30",
- "Wed:15:30-Thu:18:30"
]
]
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
]
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "gce.io/*",
- "docker.*"
]
]
}
}, - "compute": {
- "networkInterfaces": {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}, - "aliasIpRanges": {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
}, - "backendServices": {
- "backendServiceName": "test-global-tcp",
- "locationType": "regional",
- "scheme": "EXTERNAL",
- "namedPorts": {
- "name": "https",
- "ports": [
- 443,
- 8443
]
}
}, - "subnetName": "default",
- "availabilityZones": [
- "us-west1-a"
], - "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
], - "blacklist": [
- "n2d-highcpu-96"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
]
}, - "launchSpecification": {
- "metadata": {
- "key": "example_key1",
- "value": "exmample_value1"
}, - "tags": [
- "gke-cluster-name-12345-node"
], - "ipForwarding": true,
- "minCpuPlatform": "Intel Sandy Bridge",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "labels": [
- {
- "key": "spotinst-gke-original-node-pool",
- "value": "test-native-vpc__default-pool"
}
], - "rootVolumeSizeInGb": 100,
- "rootVolumeType": "pd-standard",
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "useAsTemplateOnly": false
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s"
}
}
Delete a specified Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-abcd1234",
- "method": "DELETE",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Get the configuration for a specified Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-abcd1234",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-abcd1234",
- "name": "test",
- "controllerClusterId": "test-123124",
- "gke": {
- "clusterName": "test-cluster",
- "masterLocation": "us-central1-a"
}, - "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVcpu": 750
}, - "down": {
- "evaluationPeriods": 3,
- "maxScaleDownPercentage": 30,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headRoom": {
- "cpuPerUnit": 0,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnit": 0
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true
}, - "autoUpdate": {
- "isEnabled": true
}, - "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "strategy": {
- "drainingTimeout": 60,
- "provisioningModel": "SPOT",
- "scalingOrientation": "COST",
- "preemptiblePercentage": 100,
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "scheduling": {
- "shutdownHours": {
- "isEnabled": true,
- "timeWindows": [
- [
- "Fri:15:30-Wed:14:30",
- "Wed:15:30-Thu:18:30"
]
]
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
]
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "gce.io/*",
- "docker.*"
]
]
}
}, - "compute": {
- "networkInterfaces": {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}, - "aliasIpRanges": {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
}, - "backendServices": {
- "backendServiceName": "test-global-tcp",
- "locationType": "regional",
- "scheme": "EXTERNAL",
- "namedPorts": {
- "name": "https",
- "ports": [
- 443,
- 8443
]
}
}, - "subnetName": "default",
- "availabilityZones": [
- "us-west1-a"
], - "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
], - "blacklist": [
- "n2d-highcpu-96"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
]
}, - "launchSpecification": {
- "metadata": {
- "key": "example_key1",
- "value": "exmample_value1"
}, - "tags": [
- "gke-cluster-name-12345-node"
], - "ipForwarding": true,
- "minCpuPlatform": "Intel Sandy Bridge",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "labels": [
- {
- "key": "spotinst-gke-original-node-pool",
- "value": "test-native-vpc__default-pool"
}
], - "rootVolumeSizeInGb": 100,
- "rootVolumeType": "pd-standard",
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "useAsTemplateOnly": false
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s"
}
}
All Ocean parameters are updatable, excluding the Name and controllerClusterId.
This API supports partial updates, so specific fields can be updated separately.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object The specification of the Ocean cluster. | ||||||||||||||||
|
{- "cluster": {
- "name": "test",
- "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVcpu": 750
}, - "down": {
- "evaluationPeriods": 3,
- "maxScaleDownPercentage": 30,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headRoom": {
- "cpuPerUnit": 0,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnit": 0
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true
}, - "autoUpdate": {
- "isEnabled": true
}, - "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "strategy": {
- "drainingTimeout": 60,
- "provisioningModel": "SPOT",
- "scalingOrientation": "COST",
- "preemptiblePercentage": 100,
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "scheduling": {
- "shutdownHours": {
- "isEnabled": true,
- "timeWindows": [
- [
- "Fri:15:30-Wed:14:30",
- "Wed:15:30-Thu:18:30"
]
]
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
]
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "gce.io/*",
- "docker.*"
]
]
}
}, - "compute": {
- "networkInterfaces": {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}, - "aliasIpRanges": {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
}, - "backendServices": {
- "backendServiceName": "test-global-tcp",
- "locationType": "regional",
- "scheme": "EXTERNAL",
- "namedPorts": {
- "name": "https",
- "ports": [
- 443,
- 8443
]
}
}, - "subnetName": "default",
- "availabilityZones": [
- "us-west1-a"
], - "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
], - "blacklist": [
- "n2d-highcpu-96"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
]
}, - "launchSpecification": {
- "metadata": {
- "key": "example_key1",
- "value": "exmample_value1"
}, - "tags": [
- "gke-cluster-name-12345-node"
], - "ipForwarding": true,
- "minCpuPlatform": "Intel Sandy Bridge",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "labels": [
- {
- "key": "spotinst-gke-original-node-pool",
- "value": "test-native-vpc__default-pool"
}
], - "rootVolumeSizeInGb": 100,
- "rootVolumeType": "pd-standard",
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "useAsTemplateOnly": false
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-abcd1234",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-abcd1234",
- "name": "test",
- "controllerClusterId": "test-123124",
- "gke": {
- "clusterName": "test-cluster",
- "masterLocation": "us-central1-a"
}, - "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVcpu": 750
}, - "down": {
- "evaluationPeriods": 3,
- "maxScaleDownPercentage": 30,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headRoom": {
- "cpuPerUnit": 0,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnit": 0
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true
}, - "autoUpdate": {
- "isEnabled": true
}, - "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "strategy": {
- "drainingTimeout": 60,
- "provisioningModel": "SPOT",
- "scalingOrientation": "COST",
- "preemptiblePercentage": 100,
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "scheduling": {
- "shutdownHours": {
- "isEnabled": true,
- "timeWindows": [
- [
- "Fri:15:30-Wed:14:30",
- "Wed:15:30-Thu:18:30"
]
]
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "clusterRoll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "batchMinHealthyPercentage": 100,
- "respectPdb": true
}
}
}
]
}, - "security": {
- "containerImage": {
- "approvedImages": [
- [
- "gce.io/*",
- "docker.*"
]
]
}
}, - "compute": {
- "networkInterfaces": {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}, - "aliasIpRanges": {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
}, - "backendServices": {
- "backendServiceName": "test-global-tcp",
- "locationType": "regional",
- "scheme": "EXTERNAL",
- "namedPorts": {
- "name": "https",
- "ports": [
- 443,
- 8443
]
}
}, - "subnetName": "default",
- "availabilityZones": [
- "us-west1-a"
], - "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
], - "blacklist": [
- "n2d-highcpu-96"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
]
}, - "launchSpecification": {
- "metadata": {
- "key": "example_key1",
- "value": "exmample_value1"
}, - "tags": [
- "gke-cluster-name-12345-node"
], - "ipForwarding": true,
- "minCpuPlatform": "Intel Sandy Bridge",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "labels": [
- {
- "key": "spotinst-gke-original-node-pool",
- "value": "test-native-vpc__default-pool"
}
], - "rootVolumeSizeInGb": 100,
- "rootVolumeType": "pd-standard",
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "useAsTemplateOnly": false
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s"
}
}
Reimport the cluster's configuration from GKE.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-12345abc/reImport",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "oceanId": "o-12345abc",
- "associatedClusterName": "gke-cluster",
- "isUpdated": true,
- "launchSpecs": [
- {
- "launchSpecId": "ols-12345abc",
- "associatedNodePool": "default-pool",
- "isUpdated": true
}, - {
- "launchSpecId": "ols-98765cba",
- "associatedNodePool": "pool-1",
- "isUpdated": false
}
]
}
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s"
}
}
Detach instances from your Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
drainingTimeout | integer (Applies only if shouldTerminateInstances is on) The draining timeout (in seconds) before terminating the instance. |
instancesToDetach required | Array of strings Array of instance identifiers to be detached. |
shouldDecrementTargetCapacity | boolean Determines whether the Ocean cluster's target capacity should be decremented. (Default false) |
shouldTerminateInstances | boolean Determines whether the detached instances should be terminated or not. (Default true) |
{- "instancesToDetach": [
- "sin-9d317117a0df-oesg-02cff6a8",
- "sin-49784809d76a-oesg-02cff6a8"
], - "shouldTerminateInstances": true,
- "shouldDecrementTargetCapacity": false,
- "drainingTimeout": 0
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-4c794b06/detachInstances",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
Get group’s Elastilog by
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
fromDate required | string Beginning date value using either the date format "yyyy-mm-dd; 2016-11-20" or ms "1494751821472". |
limit | integer <= 1000 Default: 500 Example: limit=200 Maximum number of lines to extract in a response. |
resourceId | string Example: resourceId=i-12345678 Filter extracted log entries for a specific resource identifier. Default: Null |
severity | string Default: "ALL" Enum: "ALL" "INFO" "DEBUG" "ERROR" "WARN" Example: severity=INFO Severity of log entries to extract. |
toDate required | string End date value using either the date format "yyyy-mm-dd; 2016-11-20" or ms "1494751821472". |
{- "request": {
- "id": "3213f42e-455e-4801-a185-cd3eb65fac5f",
- "url": "/ocean/gcp/k8s/cluster/o-e0a2bd7c/log?fromDate=2020-10-06&toDate=2020-10-08&severity=ALL&limit=500",
- "method": "GET",
- "timestamp": "2020-10-05T16:20:38.579Z"
}, - "response": {
- "status": {
- "code": "200",
- "message": "OK"
}, - "kind": "spotinst:ocean:cluster:log",
- "items": [
- {
- "message": "Ocean o-e0a2bd7c successfully created.",
- "severity": "INFO",
- "createdAt": "2020-10-07T09:51:12.000Z"
}
], - "count": "1"
}
}
Get right-sizing recommendations for an Ocean cluster and filter them according to namespace or label.
oceanId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object Optional - may be null. | |||||
|
{- "filter": {
- "namespaces": [
- "sparkSpace",
- "kube-system"
], - "attribute": {
- "type": "label",
- "key": "app",
- "operator": "Equals",
- "value": "redis"
}
}
}
{- "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:ocean:aws:k8s:cluster:rightSizing:resourceSuggestion",
- "items": [
- {
- "resourceName": "dns-controller",
- "resourceType": "deployment",
- "namespace": "kube-system",
- "suggestedCPU": 1,
- "suggestedMemory": 19,
- "requestedCPU": 50,
- "requestedMemory": 50
}, - {
- "resourceName": "kube-dns",
- "resourceType": "daemonSet",
- "namespace": "kube-system",
- "suggestedCPU": 2,
- "suggestedMemory": 20,
- "requestedCPU": 10,
- "requestedMemory": 30
}
], - "count": 2
}
}
Provides Kubernetes cluster resource usage and costs over a time interval which can be grouped and/or filtered by label/annotaion.
For example - application name (webapp, backend), environment (production, staging), version etc.
The response will contain a breakdown of the cluster resource costs($) in terms of compute (CPU, memory) and storage.
The response will group the cluster usage costs based on preselected default of application namespace or user selected label or annotation.
Within the group, resource costs are broken down per resource kind (Deployment, DaemonSet etc.).
Time Rounding Down: The CostAnalysis API applies rounding down to the hours provided during the call.
For example, the value 1707004799099 (In GMT) representing Saturday, February 3, 2024, 23:59:59.099 is rounded down to Saturday, February 3, 2024, 23:00:00.000, resulting in the omission of one hour of cost.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
endTime required | string End date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
object Describe how to filter the costs. Optional field. | |
groupBy | string Default: "namespace" Enum: "namespace" "namespace.label.${labelKey}" "resource.label.${labelKey}" "resource.annotation.${annotationKey}" "namespace.annotation.${annotationKey}" The parameter we want to group the costs by. |
startTime required | string Beginning date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
{- "startTime": "2018-06-20T11:35:02.745Z",
- "endTime": "2018-06-22T11:30:01.745Z",
- "groupBy": "namespace.label.env",
- "filter": {
- "scope": "namespace",
- "conditions": {
- "anyMatch": [
- {
- "allMatch": [
- {
- "type": "label",
- "key": "env",
- "operator": "equals",
- "value": "prod"
}, - {
- "type": "label",
- "key": "app",
- "operator": "exists"
}
]
}, - {
- "allMatch": [
- {
- "type": "annotation",
- "key": "meta.data",
- "operator": "exists"
}
]
}
]
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-abcd1234/aggregatedCosts",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "result": {
- "totalForDuration": {
- "startTime": "2018-06-20T11:35:01.745Z",
- "endTime": "2018-06-22T11:30:01.745Z",
- "summary": {
- "total": 41772.882658036,
- "compute": {
- "total": 40668.1299631538,
- "workloads": {
- "total": 40668.1299631538
}, - "headroom": {
- "total": 0
}
}, - "storage": {
- "total": 1104.7526948819,
- "block": {
- "total": 1104.7526948819,
- "pdPv": {
- "total": 1104.7526948819
}, - "pdBoot": {
- "total": 0
}
}
}
}, - "detailedCosts": {
- "groupedBy": "n.l.name",
- "aggregations": {
- "property1": {
- "summary": {
- "total": 425.23778,
- "compute": {
- "total": 125.23778
}, - "storage": {
- "total": 300,
- "block": {
- "total": 300,
- "pdPv": {
- "total": 300
}, - "pdBoot": {
- "total": 0
}
}
}
}, - "resources": [
- {
- "metadata": {
- "name": "k8s-events",
- "type": "Deployment",
- "namespace": "kube-system"
}, - "total": 1.655635222,
- "compute": {
- "total": 1.4213600158
}, - "storage": {
- "total": 0.2342752062,
- "block": {
- "total": 0.2342752062,
- "pdPv": {
- "total": 0
}, - "pdBoot": {
- "total": 0.2342752062
}
}
}
}
]
}, - "property2": {
- "summary": {
- "total": 425.23778,
- "compute": {
- "total": 125.23778
}, - "storage": {
- "total": 300,
- "block": {
- "total": 300,
- "pdPv": {
- "total": 300
}, - "pdBoot": {
- "total": 0
}
}
}
}, - "resources": [
- {
- "metadata": {
- "name": "k8s-events",
- "type": "Deployment",
- "namespace": "kube-system"
}, - "total": 1.655635222,
- "compute": {
- "total": 1.4213600158
}, - "storage": {
- "total": 0.2342752062,
- "block": {
- "total": 0.2342752062,
- "pdPv": {
- "total": 0
}, - "pdBoot": {
- "total": 0.2342752062
}
}
}
}
]
}
}
}
}
}
}
], - "count": 1,
- "kind": "ocean:k8s:cluster:aggregatedCosts:detailed"
}
}
Provides Kubernetes cluster summary usage and costs over a time interval which can be grouped and/or filtered by label/annotaion,
for example - application name (webapp, backend), environment (production, staging), version etc.
The response will contain a breakdown of the cluster resource costs($) in terms of compute (CPU, memory), storage (block, file, rootVolume).
The response will group the cluster usage costs based on preselected default of application namespace or user selected label or annotation.
Time Rounding Down: The CostAnalysis API applies rounding down to the hours provided during the call.
For example, the value 1707004799099 (In GMT) representing Saturday, February 3, 2024, 23:59:59.099 is rounded down to Saturday, February 3, 2024, 23:00:00.000, resulting in the omission of one hour of cost.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
endTime required | string End date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
object Describe how to filter the costs. Optional field. | |
groupBy | string Default: "namespace" Enum: "namespace" "namespace.label.${labelKey}" "resource.label.${labelKey}" "resource.annotation.${annotationKey}" "namespace.annotation.${annotationKey}" The parameter we want to group the costs by. |
startTime required | string Beginning date value using either the date format "yyyy-MM-dd'T'HH:mm:ss'Z'" or ms "1494751821472". |
{- "startTime": "2023-07-20T11:35:01.745Z",
- "endTime": "2023-07-22T11:30:01.745Z",
- "groupBy": "namespace.label.env",
- "filter": {
- "scope": "namespace",
- "conditions": {
- "anyMatch": [
- {
- "allMatch": [
- {
- "type": "label",
- "key": "env",
- "operator": "equals",
- "value": "prod"
}, - {
- "type": "label",
- "key": "app",
- "operator": "exists"
}
]
}, - {
- "allMatch": [
- {
- "type": "annotation",
- "key": "meta.data",
- "operator": "exists"
}
]
}
]
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-abcd1234/aggregatedCosts/summary",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "result": {
- "totalForDuration": {
- "startTime": "2023-07-20T11:35:01.745Z",
- "endTime": "2023-07-22T11:30:01.745Z",
- "summary": {
- "total": 41772.882658035785,
- "compute": {
- "total": 40668.1299631538,
- "workloads": {
- "total": 39882.13803327978
}, - "headroom": {
- "total": 0
}
}, - "storage": {
- "total": 1104.7526948819868,
- "block": {
- "total": 1104.7526948819868,
- "pdPv": {
- "total": 1104.7526948819868
}, - "pdBoot": {
- "total": 0
}
}
}
}
}
}
}
], - "count": 1,
- "kind": "ocean:k8s:cluster:aggregatedCosts:summary"
}
}
Returns all instances types that match the given filters. These instance types will be used if the cluster is configured with these filters.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (InstanceTypesFilters) List of filters. The Instance types that match with all filters compose the Ocean's whitelist parameter. Cannot be configured together with whitelist/blacklist. | ||||||||||||
|
{- "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-abcd1234/instanceTypeFiltersSimulation",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "filteredInstanceTypes": [
- "n1-highcpu-4",
- "n1-highcpu-2",
- "n1-highcpu-8",
- "n1-standard-2",
- "n1-standard-1"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s:instanceTypesFilters:simulation"
}
}
Create a Virtual Node Group.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
initialNodes | integer Default: null Example: initialNodes=1 When set to an integer greater than 0, a corresponding number of nodes will be launched from the virtual node group created. |
required | object (oceanClusterLaunchSpecCreate) Ocean Cluster Virtual Node Group (VNG). | ||||||||||||||||||||||||||||||||||||||||||||
|
{- "launchSpec": {
- "oceanId": "o-1fff54ed",
- "name": "lp_name",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "rootVolumeSizeInGb": 8,
- "rootVolumeType": "pd-standard",
- "metadata": [
- {
- "key": "key1",
- "value": "value1"
}, - {
- "key": "key2",
- "value": "value2"
}
], - "instanceTypes": [
- "n1-standard-1",
- "n1-standard-2"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
], - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "tags": [
- "gke-cluster-name-12345-node",
- "network-tag-1"
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1000,
- "memoryPerUnit": 2048,
- "gpuPerUnit": 0,
- "numOfUnits": 3
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "restrictScaleDown": false,
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "strategy": {
- "preemptiblePercentage": 80,
- "scalingOrientation": "COST",
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "storage": {
- "localSsdCount": 2
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 1
}
]
}
}
]
}, - "networkInterfaces": [
- {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": [
- {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}
], - "aliasIpRanges": [
- {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
]
}
]
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/launchSpec",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-1fff54ed",
- "name": "lp_name",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "rootVolumeSizeInGb": 8,
- "rootVolumeType": "pd-standard",
- "metadata": [
- {
- "key": "key1",
- "value": "value1"
}, - {
- "key": "key2",
- "value": "value2"
}
], - "instanceTypes": [
- "n1-standard-1",
- "n1-standard-2"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
], - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "tags": [
- "gke-cluster-name-12345-node",
- "network-tag-1"
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1000,
- "memoryPerUnit": 2048,
- "gpuPerUnit": 0,
- "numOfUnits": 3
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "restrictScaleDown": false,
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "strategy": {
- "preemptiblePercentage": 80,
- "scalingOrientation": "COST",
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "storage": {
- "localSsdCount": 2
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 1
}
]
}
}
]
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z",
- "networkInterfaces": [
- {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": [
- {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}
], - "aliasIpRanges": [
- {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
]
}
]
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s:launchSpec"
}
}
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
oceanId required | string Example: oceanId=o-12345abc Identifier of the Ocean cluster. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/launchSpec",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-1fff54ed",
- "name": "lp_name",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "rootVolumeSizeInGb": 8,
- "rootVolumeType": "pd-standard",
- "metadata": [
- {
- "key": "key1",
- "value": "value1"
}, - {
- "key": "key2",
- "value": "value2"
}
], - "instanceTypes": [
- "n1-standard-1",
- "n1-standard-2"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
], - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "tags": [
- "gke-cluster-name-12345-node",
- "network-tag-1"
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1000,
- "memoryPerUnit": 2048,
- "gpuPerUnit": 0,
- "numOfUnits": 3
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "restrictScaleDown": false,
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "strategy": {
- "preemptiblePercentage": 80,
- "scalingOrientation": "COST",
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "storage": {
- "localSsdCount": 2
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 1
}
]
}
}
]
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z",
- "networkInterfaces": [
- {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": [
- {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}
], - "aliasIpRanges": [
- {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
]
}
]
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s:launchSpec"
}
}
Returns an Ocean Virtual Node Group (VNG) configuration based on a given GCP GKE Cluster Node Pool.
The returned value ("Imported VNG") can then be used as input to the Create VNG API in order to create an actual VNG in your Ocean cluster.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
nodePoolName required | string Example: nodePoolName=test Name of the Node Pool. |
oceanId required | string Example: oceanId=o-12345abc Identifier of the Ocean cluster. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/launchSpec/import",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-1fff54ed",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "rootVolumeType": "pd-standard",
- "metadata": [
- {
- "key": "key1",
- "value": "value1"
}, - {
- "key": "key2",
- "value": "value2"
}
], - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "tags": [
- "gke-cluster-name-12345-node",
- "network-tag-1"
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "storage": {
- "localSsdCount": 2
}
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s:launchSpec"
}
}
Delete a specified virtual node group in an Ocean cluster.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
deleteNodes | boolean Default: false Example: deleteNodes=true When set to "true", all instances belonging to the deleted Virtual Node Group will be drained, detached, and terminated. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/launchSpec/ols-12345abc",
- "method": "DELETE",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
All Ocean parameters in a virtual node group are updatable.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object Object specifying the automatic scaling of an Ocean VNG. | |
availabilityZones | Array of strings An array holding availability zones, this configures the availability zones the Ocean may launch instances in per VNG. Can be null. |
object (InstanceTypesFilters) List of filters. The Instance types that match with all filters compose the Ocean's whitelist parameter. Cannot be configured together with whitelist/blacklist. | |
instanceTypes | Array of strings An array of supported machine types for the virtual node group. Can be null. |
Array of objects An array of labels to add to the virtual node group. Only custom user labels are allowed, and not Kubernetes built-in labels or Spot internal labels. | |
Array of objects Add metadata to the cluster. | |
name | string Set the name for the virtual node group. |
oceanId required | string The Ocean cluster identifier. Required to create the virtual node group. |
preferredTypes | Array of strings (preferredTypes) When Ocean scales up VMs, it prioritizes the preferred instance types for launching new nodes. If launching nodes from this preferred list is not feasible, Ocean will then proceed to utilize the configured instance types available within the cluster. Note that the preferred types must be a subset of the instance types configured for the cluster/vng. |
object | |
restrictScaleDown | boolean When set to True, VNG nodes will be treated as if all pods running have the restrict-scale-down label. Therefore, Ocean will not scale nodes down unless they are empty. |
rootVolumeSizeInGb | integer Set root volume size (in GB). |
rootVolumeType | string Enum: "pd-standard" "pd-ssd" "pd-balanced" Set the root volume disk type. |
object (Ocean Scheduling) An object used to define scheduled tasks such as a manual headroom update. | |
serviceAccount | string The account used by applications running on the VM to call GCP APIs. |
object (shielded-instance-config) The Ocean shielded instance configuration object. | |
sourceImage required | string Set the image URL. Can be null. |
object (storage) The Ocean virtual node group storage object. | |
object (strategy) The Ocean virtual node group strategy object. | |
tags | Array of strings Every node launched from this VNG will have those tags. If the value is null, the nodes will have the tags configured at the cluster level. |
Array of objects Add taints to the virtual node group. |
{- "oceanId": "o-1fff54ed",
- "name": "lp_name",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "rootVolumeSizeInGb": 8,
- "rootVolumeType": "pd-standard",
- "metadata": [
- {
- "key": "key1",
- "value": "value1"
}, - {
- "key": "key2",
- "value": "value2"
}
], - "instanceTypes": [
- "n1-standard-1",
- "n1-standard-2"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
], - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "tags": [
- "gke-cluster-name-12345-node",
- "network-tag-1"
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1000,
- "memoryPerUnit": 2048,
- "gpuPerUnit": 0,
- "numOfUnits": 3
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "restrictScaleDown": false,
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "strategy": {
- "preemptiblePercentage": 80,
- "scalingOrientation": "COST",
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "storage": {
- "localSsdCount": 2
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 1
}
]
}
}
]
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/launchSpec/ols-12345abc",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-1fff54ed",
- "name": "lp_name",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "rootVolumeSizeInGb": 8,
- "rootVolumeType": "pd-standard",
- "metadata": [
- {
- "key": "key1",
- "value": "value1"
}, - {
- "key": "key2",
- "value": "value2"
}
], - "instanceTypes": [
- "n1-standard-1",
- "n1-standard-2"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
], - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "tags": [
- "gke-cluster-name-12345-node",
- "network-tag-1"
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1000,
- "memoryPerUnit": 2048,
- "gpuPerUnit": 0,
- "numOfUnits": 3
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "restrictScaleDown": false,
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "strategy": {
- "preemptiblePercentage": 80,
- "scalingOrientation": "COST",
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "storage": {
- "localSsdCount": 2
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 1
}
]
}
}
]
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s:launchSpec"
}
}
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/launchSpec/ols-12345abc",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-1fff54ed",
- "name": "lp_name",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "rootVolumeSizeInGb": 8,
- "rootVolumeType": "pd-standard",
- "metadata": [
- {
- "key": "key1",
- "value": "value1"
}, - {
- "key": "key2",
- "value": "value2"
}
], - "instanceTypes": [
- "n1-standard-1",
- "n1-standard-2"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
], - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "tags": [
- "gke-cluster-name-12345-node",
- "network-tag-1"
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1000,
- "memoryPerUnit": 2048,
- "gpuPerUnit": 0,
- "numOfUnits": 3
}
], - "autoHeadroomPercentage": 20,
- "down": {
- "maxScaleDownPercentage": 30
}
}, - "resourceLimits": {
- "maxInstanceCount": 5,
- "minInstanceCount": 2
}, - "restrictScaleDown": false,
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "strategy": {
- "preemptiblePercentage": 80,
- "scalingOrientation": "COST",
- "shouldUtilizeCommitments": true,
- "revertToPreferred": {
- "shouldPerform": true,
- "maxBatchPercentage": 10
}
}, - "storage": {
- "localSsdCount": 2
}, - "scheduling": {
- "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "manualHeadroomUpdate",
- "config": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 1
}
]
}
}
]
}, - "createdAt": "2019-06-03T08:13:08.000Z",
- "updatedAt": "2019-06-10T15:06:13.000Z",
- "networkInterfaces": [
- {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": [
- {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}
], - "aliasIpRanges": [
- {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
]
}
]
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s:launchSpec"
}
}
Roll an entire Ocean cluster or roll subsets of the cluster by specifying launchSpecIds or instanceNames. Performing this request will start the roll immediately, and the roll will take place according to defined batches.
Note that the first response for a successful request will notify about the start of a roll. In order to check the status of a roll, you can use the GET Cluster Roll API using the roll identifier.
oceanId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object | |||||||||
|
{- "roll": {
- "batchSizePercentage": 20,
- "comment": "This is why I deployed my cluster.",
- "respectPdb": true,
- "batchMinHealthyPercentage": 100
}
}
{- "rollId": "roll-1234",
- "oceanId": "o-12e31234",
- "scope": "Cluster",
- "status": "IN_PROGRESS",
- "batchNumber": 1,
- "numOfBatches": 5,
- "comment": "This is why I deployed my cluster.",
- "respectPdb": true,
- "progress": {
- "unit": "percentage",
- "value": 0,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceName": "sin-0a4becc0-sig-1234abcd",
- "status": "REPLACED"
}, - {
- "instanceName": "sin-1a4becc0-sig-1234abcd",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceName": "sin-2a4becc0-sig-1234abcd",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "instanceName": "sin-3a4becc0-sig-1234abcd",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}
]
}
}, - "instanceNames": [
- "sin-0a4becc0-sig-6952238d",
- "sin-0542ecc0-sig-695223r4"
], - "launchSpecIds": [
- "ols-76694a7d",
- "ols-56694a76"
], - "batchMinHealthyPercentage": 100,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
Get status for all rolls of an Ocean cluster.
oceanId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:ocean:aws:k8s:cluster:roll",
- "items": [
- {
- "id": "scr-5aaf854e",
- "scope": "Cluster",
- "status": "IN_PROGRESS",
- "currentBatch": 2,
- "numOfBatches": 2,
- "comment": "This is why I deployed my cluster.",
- "progress": {
- "unit": "percentage",
- "value": 0,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceName": "sin-0a4becc0-sig-1234abcd",
- "status": "REPLACED"
}, - {
- "instanceName": "sin-1a4becc0-sig-1234abcd",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceName": "sin-2a4becc0-sig-1234abcd",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "instanceName": "sin-3a4becc0-sig-1234abcd",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}
]
}
}, - "batchMinHealthyPercentage": 100,
- "oceanId": "o-30681b13",
- "launchSpecIds": [
- [
- "ols-76694a7d",
- "ols-56694a76"
]
], - "respectPdb": true,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
]
}
Update a roll of an Ocean cluster.
Performing the request will stop the next batch in a roll.
oceanId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
rollId required | string Example: scr-12345abc Ocean Cluster Roll identifier |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object Object that specifies the parameters of a roll (also called a deployment). | |||
|
{- "roll": {
- "status": "STOPPED"
}
}
{- "rollId": "roll-1234",
- "status": "STOPPED",
- "batchNumber": 1,
- "numOfBatches": 5,
- "scope": "Cluster",
- "progress": {
- "unit": "percentage",
- "value": 0,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceName": "sin-0a4becc0-sig-1234abcd",
- "status": "REPLACED"
}, - {
- "instanceName": "sin-1a4becc0-sig-1234abcd",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceName": "sin-2a4becc0-sig-1234abcd",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "instanceName": "sin-3a4becc0-sig-1234abcd",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}
]
}
}, - "batchMinHealthyPercentage": 100,
- "oceanId": "o-12e31234",
- "respectPdb": true,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
Get status for roll of an Ocean cluster.
oceanId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
rollId required | string Example: scr-12345abc Ocean Cluster Roll identifier |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "rollId": "roll-1234",
- "oceanId": "o-12e31234",
- "scope": "Cluster",
- "status": "IN_PROGRESS",
- "batchNumber": 1,
- "numOfBatches": 5,
- "comment": "This is why I deployed my cluster.",
- "respectPdb": true,
- "progress": {
- "unit": "percentage",
- "value": 0,
- "detailedStatus": {
- "oldInstances": [
- {
- "instanceName": "sin-0a4becc0-sig-1234abcd",
- "status": "REPLACED"
}, - {
- "instanceName": "sin-1a4becc0-sig-1234abcd",
- "status": "TO_BE_REPLACED"
}, - {
- "instanceName": "sin-2a4becc0-sig-1234abcd",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "instanceName": "sin-3a4becc0-sig-1234abcd",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}
]
}
}, - "instanceNames": [
- "sin-0a4becc0-sig-6952238d",
- "sin-0542ecc0-sig-695223r4"
], - "launchSpecIds": [
- "ols-76694a7d",
- "ols-56694a76"
], - "batchMinHealthyPercentage": 100,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
Get nodes data of an Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
instanceName | string Example: instanceName=sin-123 Get a specific node by instance name. |
launchSpecId | string Example: launchSpecId=ols-123abc Ocean cluster Virtual Node Group identifier. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/o-12345abc/nodes",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "instanceName": "sin-123",
- "instanceType": "n1-standard-2",
- "availabilityZone": "us-central1-b",
- "launchSpecId": "ols-123",
- "launchSpecName": "dev-launchSpec",
- "lifeCycle": "Preemtible",
- "publicIp": "1.2.3.4",
- "workloadRequestedMilliCpu": 1320,
- "workloadRequestedMemoryInMiB": 500,
- "workloadRequestedGpu": 1,
- "headroomRequestedMilliCpu": 1320,
- "headroomRequestedMemoryInMiB": 512,
- "headroomRequestedGpu": 1,
- "allocatableMilliCpu": 2000,
- "allocatableMemoryInMiB": 3646.1,
- "allocatableGpu": 1,
- "nodeName": "node-1",
- "registrationStatus": "Registered",
- "createdAt": "2021-10-1T05:51:06.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s:nodes"
}
}
Prerequisites | Perform the following validations prior to upgrade executions: | * Group identifier cannot be null. * Group identifier exists in Elastigroup. * Group should be a GKE Elastigroup with defined scaling policy. * Group identifier is already managed by Ocean.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
groupId required | string Elastigroup identifier |
{- "request": {
- "id": "e1aba6b3-d1be-419f-b19a-9542e09716a5",
- "url": "/ocean/gcp/k8s/cluster/import?groupId=o-210e0c0b?accountId=act-7461862f",
- "method": "GET",
- "timestamp": "2019-03-05T15:43:16.306Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "kind": "spotinst:ocean:gcp:k8s",
- "items": {
- "id": "o-9aa80ccb",
- "name": "ocean test",
- "controllerClusterId": "Test-5837c8ad1",
- "gke": {
- "clusterName": "test-native-vpc",
- "masterLocation": "us-central1-a"
}, - "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "compute": {
- "networkInterfaces": {
- "network": "default",
- "accessConfigs": {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}, - "aliasIpRanges": {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
}, - "subnetName": "default",
- "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
]
}, - "launchSpecification": {
- "metadata": {
- "key": "example_key1",
- "value": "exmample_value1"
}, - "tags": [
- "gke-cluster-name-12345-node"
], - "ipForwarding": true,
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "labels": [
- {
- "key": "spotinst-gke-original-node-pool",
- "value": "test-native-vpc__default-pool"
}
], - "rootVolumeSizeInGb": 100
}, - "availabilityZones": [
- [
- "us-central1-a"
]
]
}, - "createdAt": "2018-11-05T12:55:50.000+0000",
- "updatedAt": "2018-11-05T12:58:15.000+0000"
}, - "count": 1
}
}
Returns an Ocean Cluster configuration, and optionally Virtual Node Group (VNG) configurations based on a given GKE Cluster and its Node Pools.
The returned values ("Imported Cluster/VNGs") can then be used as inputs to the Create Cluster/VNG APIs in order to create the respectful resources.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
clusterName required | string Example: clusterName=test-gke Name of the GKE Cluster. |
includeLaunchSpecs | boolean Default: true Example: includeLaunchSpecs=true When set to "true", GKE cluster node pools will be imported to Ocean custom VNG ("customLaunchSpec") configurations. |
location required | string Example: location=us-central1-a Location GKE Cluster Master. |
nodePoolName | string Example: nodePoolName=test Name of the Node Pool to use as a default for the Cluster configuration. |
required | object The specification of the Ocean cluster. | ||||||||||||||
|
{- "cluster": {
- "name": "test",
- "controllerClusterId": "test-123124",
- "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
], - "blacklist": [
- "n2d-highcpu-96"
]
}, - "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVcpu": 750
}, - "down": {
- "evaluationPeriods": 3,
- "maxScaleDownPercentage": 30,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headRoom": {
- "cpuPerUnit": 0,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnit": 0
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true
}, - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "backendServices": [
- {
- "backendServiceName": "bserv-2",
- "locationType": "regional",
- "scheme": "EXTERNAL",
- "namedPorts": {
- "name": "https",
- "ports": [
- 443,
- 8443
]
}
}
]
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/cluster/gke/import",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "name": "test",
- "controllerClusterId": "test-123124",
- "gke": {
- "clusterName": "test-cluster",
- "masterLocation": "us-central1-a"
}, - "autoScaler": {
- "isEnabled": true,
- "cooldown": 180,
- "resourceLimits": {
- "maxMemoryGib": 1500,
- "maxVcpu": 750
}, - "down": {
- "evaluationPeriods": 3,
- "maxScaleDownPercentage": 30,
- "aggressiveScaleDown": {
- "isEnabled": false
}
}, - "headRoom": {
- "cpuPerUnit": 0,
- "memoryPerUnit": 0,
- "gpuPerUnit": 0,
- "numOfUnit": 0
}, - "isAutoConfig": false,
- "autoHeadroomPercentage": null,
- "enableAutomaticAndManualHeadroom": true
}, - "autoUpdate": {
- "isEnabled": true
}, - "capacity": {
- "minimum": 0,
- "maximum": 3,
- "target": 3
}, - "compute": {
- "networkInterfaces": {
- "network": "default",
- "projectId": "test-project",
- "accessConfigs": {
- "name": "external-nat",
- "type": "ONE_TO_ONE_NAT"
}, - "aliasIpRanges": {
- "ipCidrRange": "/24",
- "subnetworkRangeName": "gke-test-native-vpc-pods-5cb557f7"
}
}, - "backendServices": {
- "backendServiceName": "test-global-tcp",
- "locationType": "regional",
- "scheme": "EXTERNAL",
- "namedPorts": {
- "name": "https",
- "ports": [
- 443,
- 8443
]
}
}, - "subnetName": "default",
- "availabilityZones": [
- "us-west1-a"
], - "instanceTypes": {
- "whitelist": [
- "n1-standard-2"
], - "blacklist": [
- "n2d-highcpu-96"
], - "filters": {
- "minVcpu": 2,
- "maxVcpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "includeFamilies": [
- "c2",
- "c3"
], - "excludeFamilies": [
- "n2",
- "c3"
]
}, - "preferredTypes": [
- "c3d-standard-4",
- "c3d-standard-8"
]
}, - "launchSpecification": {
- "metadata": {
- "key": "example_key1",
- "value": "exmample_value1"
}, - "tags": [
- "gke-cluster-name-12345-node"
], - "ipForwarding": true,
- "minCpuPlatform": "Intel Sandy Bridge",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "labels": [
- {
- "key": "spotinst-gke-original-node-pool",
- "value": "test-native-vpc__default-pool"
}
], - "rootVolumeSizeInGb": 100,
- "rootVolumeType": "pd-standard",
- "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "useAsTemplateOnly": false
}
}
}, - "customLaunchSpecs": [
- {
- "oceanId": "o-1fff54ed",
- "serviceAccount": "265168459660-compute@developer.gserviceaccount.com",
- "rootVolumeType": "pd-standard",
- "metadata": [
- {
- "key": "key1",
- "value": "value1"
}, - {
- "key": "key2",
- "value": "value2"
}
], - "availabilityZones": [
- "us-central1-a",
- "us-central1-b"
], - "tags": [
- "gke-cluster-name-12345-node",
- "network-tag-1"
], - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "labels": [
- {
- "key": "env",
- "value": "test"
}
], - "shieldedInstanceConfig": {
- "enableSecureBoot": true,
- "enableIntegrityMonitoring": true
}, - "storage": {
- "localSsdCount": 2
}
}
]
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s"
}
}
Launch nodes in virtual node group.
launchSpecId required | string Ocean cluster Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
object (Ocean GKE Virtual Node Group Launch Request) | |||
|
{- "launchRequest": {
- "amount": 5
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/gcp/k8s/launchSpec/ols-12345abc/launchNodes",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "newInstances": [
- {
- "instanceName": "sin-00b61aa5dde4-oesg-97499562",
- "availabilityZone": "us-west-2b",
- "instanceType": "c3.xlarge",
- "lifeCycle": "Preemptible"
}
]
}
], - "count": 1,
- "kind": "spotinst:ocean:gcp:k8s:launchSpec:launchNodes",
- "launchSpecId": "ols-f73821bc"
}
}
Creates an Ocean entity according to a given specification.
Notes:
It is recommended to import all necessary information from the existing AKS cluster using the Ocean AKS Cluster Import API call and use its output to create a fully configured Ocean cluster.
The Ocean Controller is used to monitor the cluster resources and report back to Ocean SaaS. A properly functioning controller is mandatory for Ocean to operate.
Installing the controller can be easily done by Helm, Terraform or a script using the guide.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (ocean-cluster-2) The Ocean cluster. | ||||||||||||||||
|
{- "cluster": {
- "name": "test",
- "controllerClusterId": "test-123124",
- "aks": {
- "clusterName": "test-cluster",
- "resourceGroupName": "TestResourceGroup",
- "region": "eastus",
- "infrastructureResourceGroupName": "MC_TestResourceGroup_test-cluster_eastus"
}, - "autoScaler": {
- "isEnabled": true,
- "resourceLimits": {
- "maxVCpu": 750,
- "maxMemoryGib": 1500
}, - "down": {
- "maxScaleDownPercentage": 30
}, - "headroom": {
- "automatic": {
- "isEnabled": true,
- "percentage": 5
}
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "batchSizePercentage": 20,
- "comment": "Scheduled cluster roll",
- "respectPdb": true,
- "respectRestrictScaleDown": true,
- "batchMinHealthyPercentage": 80,
- "vngIds": [
- "vng-123456"
]
}
}
], - "suspensionHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "azureBlob": {
- "id": "di-123"
}
}
}, - "health": {
- "gracePeriod": 600
}, - "virtualNodeGroupTemplate": {
- "availabilityZones": [
- "0",
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-134abcd",
- "name": "test",
- "controllerClusterId": "test-123124",
- "aks": {
- "clusterName": "test-cluster",
- "resourceGroupName": "TestResourceGroup",
- "region": "eastus",
- "infrastructureResourceGroupName": "MC_TestResourceGroup_test-cluster_eastus"
}, - "autoScaler": {
- "isEnabled": true,
- "resourceLimits": {
- "maxVCpu": 750,
- "maxMemoryGib": 1500
}, - "down": {
- "maxScaleDownPercentage": 30
}, - "headroom": {
- "automatic": {
- "isEnabled": true,
- "percentage": 5
}
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "batchSizePercentage": 20,
- "comment": "Scheduled cluster roll",
- "respectPdb": true,
- "respectRestrictScaleDown": true,
- "batchMinHealthyPercentage": 80,
- "vngIds": [
- "vng-123456"
]
}
}
], - "suspensionHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "azureBlob": {
- "id": "di-123"
}
}
}, - "health": {
- "gracePeriod": 600
}, - "virtualNodeGroupTemplate": {
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np"
}
}
List the configurations for all Ocean clusters in the specified account.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-134abcd",
- "name": "test",
- "controllerClusterId": "test-123124",
- "aks": {
- "clusterName": "test-cluster",
- "resourceGroupName": "TestResourceGroup",
- "region": "eastus",
- "infrastructureResourceGroupName": "MC_TestResourceGroup_test-cluster_eastus"
}, - "autoScaler": {
- "isEnabled": true,
- "resourceLimits": {
- "maxVCpu": 750,
- "maxMemoryGib": 1500
}, - "down": {
- "maxScaleDownPercentage": 30
}, - "headroom": {
- "automatic": {
- "isEnabled": true,
- "percentage": 5
}
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "batchSizePercentage": 20,
- "comment": "Scheduled cluster roll",
- "respectPdb": true,
- "respectRestrictScaleDown": true,
- "batchMinHealthyPercentage": 80,
- "vngIds": [
- "vng-123456"
]
}
}
], - "suspensionHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "azureBlob": {
- "id": "di-123"
}
}
}, - "health": {
- "gracePeriod": 600
}, - "virtualNodeGroupTemplate": {
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np"
}
}
Get the configurations for a specified Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/o-12345abc",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-134abcd",
- "name": "test",
- "controllerClusterId": "test-123124",
- "aks": {
- "clusterName": "test-cluster",
- "resourceGroupName": "TestResourceGroup",
- "region": "eastus",
- "infrastructureResourceGroupName": "MC_TestResourceGroup_test-cluster_eastus"
}, - "autoScaler": {
- "isEnabled": true,
- "resourceLimits": {
- "maxVCpu": 750,
- "maxMemoryGib": 1500
}, - "down": {
- "maxScaleDownPercentage": 30
}, - "headroom": {
- "automatic": {
- "isEnabled": true,
- "percentage": 5
}
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "batchSizePercentage": 20,
- "comment": "Scheduled cluster roll",
- "respectPdb": true,
- "respectRestrictScaleDown": true,
- "batchMinHealthyPercentage": 80,
- "vngIds": [
- "vng-123456"
]
}
}
], - "suspensionHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "azureBlob": {
- "id": "di-123"
}
}
}, - "health": {
- "gracePeriod": 600
}, - "virtualNodeGroupTemplate": {
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np"
}
}
Update a specified Ocean cluster.
This API supports partial updates, so specific fields can be updated separately.
Notes:
When labels, tags and taints are updated in the VNG template, all existing nodes from VNGs that inherit these properties
from the tamplate will be updated as well.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (ocean-cluster-3) The Ocean cluster. | ||||||||||||
|
{- "cluster": {
- "name": "test",
- "autoScaler": {
- "isEnabled": true,
- "resourceLimits": {
- "maxVCpu": 750,
- "maxMemoryGib": 1500
}, - "down": {
- "maxScaleDownPercentage": 30
}, - "headroom": {
- "automatic": {
- "isEnabled": true,
- "percentage": 5
}
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "batchSizePercentage": 20,
- "comment": "Scheduled cluster roll",
- "respectPdb": true,
- "respectRestrictScaleDown": true,
- "batchMinHealthyPercentage": 80,
- "vngIds": [
- "vng-123456"
]
}
}
], - "suspensionHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "azureBlob": {
- "id": "di-123"
}
}
}, - "health": {
- "gracePeriod": 600
}, - "virtualNodeGroupTemplate": {
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/o-12345abc",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "o-134abcd",
- "name": "test",
- "controllerClusterId": "test-123124",
- "aks": {
- "clusterName": "test-cluster",
- "resourceGroupName": "TestResourceGroup",
- "region": "eastus",
- "infrastructureResourceGroupName": "MC_TestResourceGroup_test-cluster_eastus"
}, - "autoScaler": {
- "isEnabled": true,
- "resourceLimits": {
- "maxVCpu": 750,
- "maxMemoryGib": 1500
}, - "down": {
- "maxScaleDownPercentage": 30
}, - "headroom": {
- "automatic": {
- "isEnabled": true,
- "percentage": 5
}
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "batchSizePercentage": 20,
- "comment": "Scheduled cluster roll",
- "respectPdb": true,
- "respectRestrictScaleDown": true,
- "batchMinHealthyPercentage": 80,
- "vngIds": [
- "vng-123456"
]
}
}
], - "suspensionHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "logging": {
- "export": {
- "azureBlob": {
- "id": "di-123"
}
}
}, - "health": {
- "gracePeriod": 600
}, - "virtualNodeGroupTemplate": {
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np"
}
}
Delete a specified Ocean cluster.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/o-12345abc",
- "method": "DELETE",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
The Import Cluster API call returns a JSON formatted Ocean cluster specification for a given AKS cluster and import identifier. The returned specification is ready to use in the Ocean AKS Cluster Create API call.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
aksClusterName required | string Example: aksClusterName=test-cluster The name of the aks cluster. |
resourceGroupName required | string Example: resourceGroupName=test-clust_group The name of the resource group of the AKS cluster. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/aks/import",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "cluster": {
- "id": "o-134abcd",
- "name": "test",
- "controllerClusterId": "test-123124",
- "aks": {
- "clusterName": "test-cluster",
- "resourceGroupName": "TestResourceGroup",
- "region": "eastus",
- "infrastructureResourceGroupName": "MC_TestResourceGroup_test-cluster_eastus"
}, - "autoScaler": {
- "isEnabled": true,
- "resourceLimits": {
- "maxVCpu": 750,
- "maxMemoryGib": 1500
}, - "down": {
- "maxScaleDownPercentage": 30
}, - "headroom": {
- "automatic": {
- "isEnabled": true,
- "percentage": 5
}
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}, - "tasks": [
- {
- "isEnabled": true,
- "cronExpression": "0 1 * * *",
- "taskType": "clusterRoll",
- "parameters": {
- "batchSizePercentage": 20,
- "comment": "Scheduled cluster roll",
- "respectPdb": true,
- "respectRestrictScaleDown": true,
- "batchMinHealthyPercentage": 80,
- "vngIds": [
- "vng-123456"
]
}
}
], - "suspensionHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "health": {
- "gracePeriod": 600
}, - "virtualNodeGroupTemplate": {
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { }
}
}
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np"
}
}
Launch new nodes for a cluster.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
adjustment required | integer >= 1 The number of nodes to launch. |
applicableVmSizes | Array of strings >= 1 |
availabilityZones | Array of strings An Array holding Availability Zones, this configures the availability zones the Ocean may launch instances in per VNG. |
minCoresPerNode | integer >= 2 Minimum number of core per node. |
minMemoryGiBPerNode | number <float> >= 2 Minimum memory per node. |
oceanId required | string Ocean cluster identifier. |
preferredLifecycle | string Enum: "Spot" "Regular" The preferred life cycle to launch the node. If not specified, the life cycle is chosen accoring to the scaled VNG. |
vngIds | Array of strings >= 1 |
{- "oceanId": "o-134abcd",
- "vngIds": [
- "vng-12345abc"
], - "preferredLifecycle": "Spot",
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "adjustment": 2,
- "minCoresPerNode": 2,
- "minMemoryGiBPerNode": 2,
- "applicableVmSizes": [
- "string"
]
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/launchNewNodes",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "vngScalingUpResults": [
- {
- "vngId": "vng-12345abc",
- "scaleNodePoolName": "omnp9e26aa3e",
- "vmSizeName": "standard_d2as_v5",
- "zones": [
- "1"
], - "lifeCycle": "Spot",
- "numOfNewScaleNodes": 1
}
], - "nodesLeftToScale": 0
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:cluster:launchNodes"
}
}
Detach Nodes nodes for a cluster.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
nodeNamesToDetach required | Array of strings >= 1 Node names to detach from the Ocean cluster. |
oceanId required | string Ocean cluster identifier. |
{- "oceanId": "o-134abcd",
- "nodeNamesToDetach": [
- "aks-omnpf52d2a6b-36204769-vmss000012"
]
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/detachNodes",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "oceanId": "o-134abcd",
- "detachedNodeNames": [
- "aks-omnpf52d2a6b-36204769-vmss000012"
]
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:cluster:detachNodes"
}
}
Create a virtual node group.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (Ocean AKS Virtual Node Group) | ||||||||||||||||||||||||
|
{- "virtualNodeGroup": {
- "name": "testVng",
- "oceanId": "o-134abcd",
- "availabilityZones": [
- "0",
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/virtualNodeGroup",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "vng-134abcd",
- "name": "testVng",
- "oceanId": "o-134abcd",
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:virtualNodeGroup"
}
}
List the configurations for all virtual node groups in the account or in a specified cluster.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
oceanId required | string Example: oceanId=o-12345abc Identifier of the Ocean cluster. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/virtualNodeGroup",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "vng-134abcd",
- "name": "testVng",
- "oceanId": "o-134abcd",
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:virtualNodeGroup"
}
}
Get the configuration of a specified virtual node group.
virtualNodeGroupId required | string Example: vng-12345abc Ocean Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/virtualNodeGroup/vng-12345abc",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "vng-134abcd",
- "name": "testVng",
- "oceanId": "o-134abcd",
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:virtualNodeGroup"
}
}
Update a specified virtual node group in an Ocean cluster.
This API supports partial updates, so specific fields can be updated separately.
Notes:
When labels, tags and taints are updated the existing nodes are updated as well.
virtualNodeGroupId required | string Example: vng-12345abc Ocean Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
required | object (Ocean AKS Virtual Node Group) | ||||||||||||||||||||||
|
{- "virtualNodeGroup": {
- "name": "testVng",
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}
}
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/virtualNodeGroup/vng-12345abc",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "vng-134abcd",
- "name": "testVng",
- "oceanId": "o-134abcd",
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "autoScale": {
- "headrooms": [
- {
- "cpuPerUnit": 1024,
- "memoryPerUnit": 512,
- "gpuPerUnit": 0,
- "numOfUnits": 2
}
]
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { },
- "vmSizes": {
- "filters": {
- "minVCpu": 2,
- "maxVCpu": 16,
- "minMemoryGiB": 8,
- "maxMemoryGiB": 16,
- "architectures": [
- "x86_64"
], - "series": [
- "D v3",
- "F",
- "E v4"
], - "excludeSeries": [
- "Bs",
- "Da v4"
], - "minDisk": 1,
- "minGpu": 1,
- "maxGpu": 2,
- "diskPerformance": "Standard",
- "acceleratedNetworking": "Enabled",
- "minNICs": 4,
- "vmTypes": [
- "memoryOptimized"
], - "gpuTypes": [
- [
- "nvidia-tesla-t4"
]
]
}
}, - "scheduling": {
- "shutdownHours": {
- "timeWindows": [
- "Sat:08:00-Sun:08:00"
], - "isEnabled": true
}
}, - "createdAt": "2021-03-17T08:13:08.000Z",
- "updatedAt": "2021-03-17T15:06:13.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:virtualNodeGroup"
}
}
Delete a specified virtual node group in an Ocean cluster.
virtualNodeGroupId required | string Example: vng-12345abc Ocean Virtual Node Group identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
deleteNodes | boolean Default: false Example: deleteNodes=true When set to "true", all instances belonging to the deleted Virtual Node Group will be drained, detached, and terminated. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/virtualNodeGroup/vng-12345abc",
- "method": "DELETE",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}
}
}
The Import Ocean Virtual Node Group (VNG) returns a JSON formatted Ocean Virtual Node Group specification based on a given AKS Node Pool. The returned specification is ready to use in the Ocean AKS Virtual Node Group Create API call.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
nodePoolName required | string Example: nodePoolName=nodePoolNameTest The name of the Node Pool. |
oceanId required | string Example: oceanId=o-12345abc Identifier of the Ocean cluster. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/virtualNodeGroup/import",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "virtualNodeGroup": {
- "name": "testVng",
- "oceanId": "o-134abcd",
- "availabilityZones": [
- "1",
- "2",
- "3"
], - "nodePoolProperties": {
- "maxPodsPerNode": 30,
- "enableNodePublicIP": true,
- "osDiskSizeGB": 64,
- "osDiskType": "Managed",
- "osType": "Linux",
- "osSKU": "Ubuntu",
- "kubernetesVersion": 1.26,
- "vnetSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "podSubnetIDs": [
- "/subscriptions/123456-1234-1234-1234-123456789/resourceGroups/ExampleResourceGroup/providers/Microsoft.Network/virtualNetworks/ExampleVirtualNetwork/subnets/default"
], - "linuxOSConfig": {
- "sysctls": {
- "vmMaxMapCount": 79550
}
}
}, - "nodeCountLimits": {
- "minCount": 1,
- "maxCount": 100
}, - "strategy": {
- "spotPercentage": 50,
- "fallbackToOd": true
}, - "labels": {
- "key": "value"
}, - "taints": [
- {
- "key": "taintKey",
- "value": "taintValue",
- "effect": "NoSchedule"
}
], - "tags": { }
}
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np"
}
}
Get the allowed VM sizes that can be launched according to the virtual node group properties and selected VM size filters.
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
virtualNodeGroupId required | string Example: virtualNodeGroupId=vng-12345abc Ocean Virtual Node Group identifier. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/virtualNodeGroup/vmSizes",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "allowedVmSizes": [
- "standard_d2",
- "standard_d2_v2",
- "standard_d2_v3",
- "standard_d2_v4",
- "standard_d2_v5"
], - "numOfAllowedVmSizes": 5
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:k8s:np:virtualNodeGroup:allowedVmSizes"
}
}
Roll an entire Ocean cluster or roll subsets of the cluster by specifying vngIds, nodePoolNames or nodeNames. Performing this request will start the roll immediately and run it in defined batches. Note that the first response for a successful request will indicate the start of a roll. In order to check the status of a roll, you can use the GET Roll API.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
batchMinHealthyPercentage | integer Default: 50 Indicates the threshold of minimum healthy nodes in single batch. If the amount of healthy nodes in single batch is under the threshold, the roll will fail. If exists, the parameter value will be in range of 1-100. In case of null as value, the default value in the backend will be 50%. Value of param should represent the number in percentage (%) of the batch. |
batchSizePercentage | integer Value as a percent to set the size of a batch in a roll. Valid values are 0-100. In case of null as value, the default value in the backend will be 20%. |
comment | string Add a comment description for the roll. The comment is limited to 256 chars and optional. |
respectPdb | boolean Default: true During the roll, if the parameter is set to true we honor PDB during the nodes replacement. |
respectRestrictScaleDown | boolean Default: false During the roll, if the parameter is set to true we honor Restrict Scale Down label during the nodes replacement. |
{- "batchSizePercentage": 25,
- "comment": "This is why I deployed my cluster.",
- "respectPdb": false,
- "respectRestrictScaleDown": true,
- "batchMinHealthyPercentage": 100
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/o-12345abc/roll",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-12345abc",
- "oceanId": "o-12e31234",
- "type": "manual",
- "scope": "Cluster",
- "status": "IN_PROGRESS",
- "currentBatch": 1,
- "numOfBatches": 2,
- "comment": "This is why I deployed my cluster.",
- "progress": {
- "progressPercentage": 0,
- "detailedStatus": {
- "rollNodes": [
- {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000q",
- "status": "IN_PROGRESS"
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss000008",
- "status": "TO_BE_REPLACED"
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000r",
- "status": "TO_BE_REPLACED"
}, - {
- "nodeName": "aks-omnpe9429a2f-26725402-vmss00000z",
- "status": "IN_PROGRESS"
}, - {
- "nodeName": "aks-omnp0c85c2c2-26833420-vmss000001",
- "status": "IN_PROGRESS"
}, - {
- "nodeName": "aks-omnp0c85c2c2-26833420-vmss000003",
- "status": "TO_BE_REPLACED"
}
]
}
}, - "respectPdb": true,
- "respectRestrictScaleDown": false,
- "batchMinHealthyPercentage": 70,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:roll"
}
}
Get status for all rolls of an Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/o-12345abc/roll",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-12345abc",
- "oceanId": "o-12e31234",
- "type": "manual",
- "scope": "Cluster",
- "status": "COMPLETED",
- "currentBatch": 1,
- "numOfBatches": 2,
- "comment": "This is why I deployed my cluster.",
- "progress": {
- "progressPercentage": 0,
- "detailedStatus": {
- "rollNodes": [
- {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000q",
- "status": "REPLACED"
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss000008",
- "status": "TO_BE_REPLACED"
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000r",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "nodeName": "aks-omnpe9429a2f-26725402-vmss00000z",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}, - {
- "nodeName": "aks-omnp0c85c2c2-26833420-vmss000001",
- "status": "IN_PROGRESS"
}, - {
- "nodeName": "aks-omnp0c85c2c2-26833420-vmss000003",
- "status": "DID_NOT_REPLACE"
}
]
}
}, - "respectPdb": true,
- "respectRestrictScaleDown": false,
- "batchMinHealthyPercentage": 70,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:roll"
}
}
Get status for a roll of an Ocean cluster.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
rollId required | string Example: acr-12345abc Ocean cluster roll identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/o-12345abc/roll/scr-12345abc",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-12345abc",
- "oceanId": "o-12e31234",
- "type": "manual",
- "scope": "Cluster",
- "status": "COMPLETED",
- "currentBatch": 1,
- "numOfBatches": 2,
- "comment": "This is why I deployed my cluster.",
- "progress": {
- "progressPercentage": 0,
- "detailedStatus": {
- "rollNodes": [
- {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000q",
- "status": "REPLACED"
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss000008",
- "status": "TO_BE_REPLACED"
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000r",
- "status": "COULD_NOT_BE_REPLACED"
}, - {
- "nodeName": "aks-omnpe9429a2f-26725402-vmss00000z",
- "status": "NOT_REPLACED_DUE_TO_PDB"
}, - {
- "nodeName": "aks-omnp0c85c2c2-26833420-vmss000001",
- "status": "IN_PROGRESS"
}, - {
- "nodeName": "aks-omnp0c85c2c2-26833420-vmss000003",
- "status": "DID_NOT_REPLACE"
}
]
}
}, - "respectPdb": true,
- "respectRestrictScaleDown": false,
- "batchMinHealthyPercentage": 70,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:roll"
}
}
Stop a roll of an Ocean cluster.
Performing the request will stop the next batch in a roll.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
rollId required | string Example: acr-12345abc Ocean cluster roll identifier. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/o-12345abc/roll/scr-12345abc/stop",
- "method": "PUT",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-12345abc",
- "oceanId": "o-12e31234",
- "type": "manual",
- "scope": "Cluster",
- "status": "STOPPED",
- "currentBatch": 1,
- "numOfBatches": 2,
- "comment": "This is why I deployed my cluster.",
- "progress": {
- "progressPercentage": 0,
- "detailedStatus": {
- "rollNodes": [
- {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000q",
- "status": "REPLACED"
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss000008",
- "status": "DID_NOT_REPLACE"
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000r",
- "status": "DID_NOT_REPLACE"
}, - {
- "nodeName": "aks-omnpe9429a2f-26725402-vmss00000z",
- "status": "REPLACED"
}, - {
- "nodeName": "aks-omnp0c85c2c2-26833420-vmss000001",
- "status": "REPLACED"
}, - {
- "nodeName": "aks-omnp0c85c2c2-26833420-vmss000003",
- "status": "DID_NOT_REPLACE"
}
], - "progressPercentage": 50
}
}, - "respectPdb": true,
- "respectRestrictScaleDown": false,
- "batchMinHealthyPercentage": 70,
- "createdAt": "2019-03-24T15:46:09.000Z",
- "updatedAt": "2019-03-24T15:46:09.000Z"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:np:roll"
}
}
Get information about nodes which can be migrated into Ocean.
oceanClusterId required | string Example: o-12345abc Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
shouldFetchPods | boolean Example: shouldFetchPods=true Should fetch data about running pods for each node. |
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "ocean/azure/np/cluster/o-abcd1234/migration/discovery",
- "method": "GET",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "nodeName": "aks-mynodepool-18735776-vmss000001",
- "nodePoolName": "mynodepool",
- "runningPods": "6"
}
], - "count": 1,
- "kind": "spotinst:ocean:azure:k8s:np:nodePoolUnmanaged"
}
}
Migrate to ocean workloads that run on unmanaged nodes by specifying nodePoolNames or nodeNames. Performing this request will start the migration immediately and run it in defined batches. Note that the first response for a successful request will indicate the start of a migration. In order to check the status of a migration, you can use the GET migration API.
oceanClusterId required | string Example: o-abcd1234 Identifier of the Ocean cluster. |
accountId required | string Example: accountId=act-123456789 The ID of the account associated with your token. |
batchMinHealthyPercentage | integer [ 1 .. 100 ] Default: 50 Indicates the threshold of minimum healthy nodes in single batch. If the amount of healthy nodes in single batch is under the threshold, the migration will fail. If exists, the parameter value will be in range of 1-100. In case of null as value, the default value in the backend will be 50%. Value of param should represent the number in percentage (%) of the batch. |
batchSizePercentage | integer [ 1 .. 100 ] Value as a percent to set the size of a batch in a migration. Valid values are 0-100. In case of null as value, the default value in the backend will be 20%. |
comment | string Add a comment description for the migration. The comment is limited to 256 chars and optional. |
nodeNames | Array of strings List of node names to be migrated. Each identifier is a string. nodeNames can be null, and cannot be used together with nodePoolNames. |
respectPdb | boolean Default: true During the migration, if the parameter is set to true we honor PDB during the nodes replacement. |
respectRestrictScaleDown | boolean Default: false During the migration, if the parameter is set to true we honor Restrict Scale Down label during the nodes replacement. |
shouldEvictStandalonePods | boolean Default: true If the parameter is set to true we will evict all standalone pods during the migration. |
shouldTerminateNodes | boolean Default: true If the parameter is set to true we will terminate the node after the migration has finished successfully. If the parameter is set to false we will leave the nodes. example: true |
{- "batchSizePercentage": 25,
- "comment": "This is why I deployed my cluster.",
- "respectPdb": false,
- "respectRestrictScaleDown": true,
- "shouldTerminateNodes": true,
- "shouldEvictStandalonePods": true,
- "batchMinHealthyPercentage": 100,
- "nodeNames": [
- [
- "aks-omnpbc2ebdb1-15563275-vmss00000g",
- "aks-omnpe9429a2f-26725402-vmss000015"
]
]
}
{- "request": {
- "id": "e593ff58-067d-4340-92f9-8b1c0bad70d7",
- "url": "/ocean/azure/np/cluster/o-12345abc/migration",
- "method": "POST",
- "timestamp": "2018-06-20T11:35:01.745Z"
}, - "response": {
- "status": {
- "code": 200,
- "message": "OK"
}, - "items": [
- {
- "id": "scr-12345abc",
- "oceanId": "o-12e31234",
- "status": "COMPLETED",
- "currentBatch": 1,
- "numOfBatches": 2,
- "comment": "migration comment.",
- "migrationProgress": {
- "progressPercentage": 0,
- "detailedStatus": {
- "oldNodes": [
- {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss00000q",
- "nodePoolName": "omnpbc2ebdb1",
- "status": "REPLACED",
- "podDetails": [
- {
- "podName": "pod-example-name1"
}
], - "runningPods": 1
}, - {
- "nodeName": "aks-omnpbc2ebdb1-15563275-vmss000008",
- "nodePoolName": "omnpbc2ebdb1",
- "status": "TO_BE_REPLACED",
- "podDetails": [
- {
- "podName": "pod-example-name2"
}, - {
- "podName": "pod-example-name3"
}
], - "runningPods": 2
}, - {
- "nodeName": "aks-omnpbc