---
title: "Initiate EKS AMI Auto Update"
method: PUT
path: "/ocean/aws/eks/cluster/{oceanClusterId}/amiAutoUpdate"
tags: ["Ocean AWS"]
---

# Initiate EKS AMI Auto Update

`PUT /ocean/aws/eks/cluster/{oceanClusterId}/amiAutoUpdate`

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.

## Parameters

- `#/paths/~1ocean~1aws~1ecs~1cluster~1%7BoceanClusterId%7D/get/parameters/1` — unresolved $ref
- `#/paths/~1azure~1costs/get/parameters/0` — unresolved $ref

## Request body

- object — The object specifying the request to trigger an AMI auto update operation
  - `amiAutoUpdate` object
    - `patch` boolean — When set to 'true', the auto-update process will update the VNGs’ images with the latest security patches. Either "patch" or "minorVersion" must be true.
    - `minorVersion` boolean — When set to 'true', the auto-update process will update the VNGs’ AMI with the AMI to match the Kubernetes control plane version. Either "patch" or "minorVersion" must be true.
    - `applyRoll` boolean — This parameter is optional. When the AMI is updated according to the configuration set, a cluster roll can be triggered.
    - `clusterRoll` object — Cluster roll configuration.
      - `batchSizePercentage` integer — Value as a percent to set the size of a batch in a roll. Valid values are 0-100.
      - `batchMinHealthyPercentage` integer — Indicates the threshold of minimum healthy instances in single batch. If the amount of healthy instances in single batch is under the threshold, the cluster 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.
      - `comment` string — Add a brief description for the roll. The comment is limited to 256 chars.
      - `respectPdb` boolean — During the roll, if the parameter is set to true we honor PDB during the instance replacement.

## Other responses

- `400` — Bad Request

---

[API](https://skmtc.net/spot/apis/spot-by-flexera-api.md) · [All operations](https://skmtc.net/spot/apis/spot-by-flexera-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/spot/spot-by-flexera-api/revisions/72813baf8d47/schema)
