Updated on 2025-12-08 GMT+08:00

Updating a Release

Function

This API is used to update a release.

Calling Method

For details, see Calling APIs.

URI

PUT /cce/cam/v3/clusters/{cluster_id}/namespace/{namespace}/releases/{name}

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

name

Yes

String

Release name

namespace

Yes

String

Namespace of the chart

cluster_id

Yes

String

Details:

Cluster ID. For details about how to obtain the value, see How to Obtain Parameters in the API URI.

Constraints:

None

Options:

Cluster IDs

Default value:

N/A

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

show_resources

No

String

Definition

Whether to display the resource information of a release

Constraints

N/A

Range

If this parameter is set to true, the resource information of the release will be displayed. If this parameter is not specified, the resource information is not displayed by default.

Default Value

N/A

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

Content-Type

Yes

String

Details:

The request body type or format

Constraints:

The GET method is not verified.

Options:

  • application/json

  • application/json;charset=utf-8

  • application/x-pem-file

  • multipart/form-data (used when the FormData parameter is present)

Default value:

N/A

X-Auth-Token

Yes

String

Details:

Requests for calling an API can be authenticated using either a token or AK/SK. If token-based authentication is used, this parameter is mandatory and must be set to a user token. For details, see Obtaining a User Token.

Constraints:

None

Options:

N/A

Default value:

N/A

Table 4 Request body parameters

Parameter

Mandatory

Type

Description

chart_id

Yes

String

Chart ID

action

Yes

String

upgrade for an upgrade and rollback for a rollback

parameters

Yes

ReleaseReqBodyParams object

Release parameters

values

Yes

values object

Release value

Table 5 ReleaseReqBodyParams

Parameter

Mandatory

Type

Description

dry_run

No

Boolean

After this function is enabled, only chart parameters are verified, and installation is not performed.

name_template

No

String

Release name template

no_hooks

No

Boolean

Whether to disable hooks during installation

replace

No

Boolean

Whether to replace the release with the same name

recreate

No

Boolean

Whether to rebuild the release

reset_values

No

Boolean

Whether to reset values during an update

release_version

No

Integer

Version of the rollback release

include_hooks

No

Boolean

Enable hooks during an update or deletion.

Table 6 values

Parameter

Mandatory

Type

Description

imagePullPolicy

No

String

Image pull policy

imageTag

No

String

Image tag

Response Parameters

Status code: 200

Table 7 Response body parameters

Parameter

Type

Description

chart_name

String

Chart name

chart_public

Boolean

Whether the chart is public

chart_version

String

Chart version

cluster_id

String

Cluster ID

cluster_name

String

Current name

create_at

String

Creation time.

description

String

Release description

name

String

Release name

namespace

String

Namespace to which a chart release belongs

parameters

String

Release parameters

resources

String

Resources required by the release

status

String

Release status.

  • DEPLOYED: The release is normal.

  • DELETED: The release has been deleted.

  • FAILED: The release fails to be deployed.

  • DELETING: The release is being deleted.

  • PENDING_INSTALL: The release is waiting to be installed.

  • PENDING_UPGRADE: The release is waiting to be upgraded.

  • PENDING_ROLLBACK: The release is waiting for rollback.

  • UNKNOWN: The release status is unknown, indicating that the release is abnormal. You can manually delete the release and reinstall it.

status_description

String

Release status description

update_at

String

Update time.

values

String

Release value

version

Integer

Release version

Example Requests

PUT /cce/cam/v3/clusters/{cluster_id}/namespace/{namespace}/releases/{name}

{
  "chart_id" : "af4b699e-018c-11ec-b8b0-0255ac100b05",
  "action" : "upgrade",
  "parameters" : {
    "dry_run" : false,
    "name_template" : "string",
    "no_hooks" : false,
    "replace" : false,
    "recreate" : false,
    "reset_values" : false,
    "release_version" : 1,
    "include_hooks" : false
  },
  "values" : {
    "imagePullPolicy" : "IfNotPresent",
    "imageTag" : "v2"
  }
}

Example Responses

Status code: 200

OK

{
  "chart_name" : "magento-mysql",
  "chart_public" : false,
  "chart_version" : "1.0.0",
  "cluster_id" : "a870253f-5dc7-11ee-bf71-0255ac100b03",
  "cluster_name" : "sfs-turbo-test",
  "create_at" : "2023-11-14T20:30:57+08:00",
  "description" : "Initial install underway",
  "name" : "testwww",
  "namespace" : "monitoring",
  "parameters" : "",
  "resources" : "",
  "status" : "PENDING_INSTALL",
  "status_description" : "Initial install underway",
  "update_at" : "2023-11-14T20:30:57+08:00",
  "values" : "{\"basic\":{\"admin_password\":\"******\",\"admin_username\":\"username\",\"app_name\":\"magento\",\"mysql_database\":\"magento\",\"mysql_name\":\"mysql\",\"mysql_password\":\"******\",\"mysql_port\":3306,\"mysql_root_password\":\"******\",\"mysql_user\":\"magento\",\"storage_class\":\"csi-nas\",\"storage_mode\":\"ReadWriteMany\",\"storage_size\":\"10G\"},\"global\":{\"magento_EIP\":\"100.100.100.100\",\"magento_EPORT\":32080,\"namespace\":\"default\"},\"image\":{\"magento_image\":\"example.com/everest/magento:latest\",\"mysql_image\":\"example.com/everest/mysql:5.7.14\"}}",
  "version" : 1
}

Status Codes

Status Code

Description

200

OK

Error Codes

See Error Codes.