Creates an asynchronous task to store a specified container in an elastic container instance as an image and pushes the image to an image repository of Alibaba Cloud Container Registry.
Operation description
You must specify the Alibaba Cloud Resource Name (ARN) of the RAM role of the Container Registry Enterprise Edition instance to grant the elastic container instance to assume the RAM role to push images.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
eci:CommitContainer | create |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID of the instance. | cn-hangzhou |
ContainerGroupId | string | Yes | The ID of the container group. | eci-bp1do4xz75fa5sd**** |
ContainerName | string | Yes | The name of the container. | container-1 |
Image | object | No | The image of the container. | |
Repository | string | Yes | The image repository. | registry-vpc.cn-hangzhou.aliyuncs.com/eastest/registry-test |
Tag | string | Yes | The tag of the image. This parameter is empty by default, which indicates that the tag is not modified. | 0.0.6 |
Message | string | No | The message about the image. | test commit |
Author | string | No | The authorization of the image. | ECI |
AcrRegistryInfo | object | No | The access credential configurations of the Container Registry Enterprise Edition instance. Note
If you use a Container Registry Personal Edition instance, you do not need to configure this parameter. If you use a Container Registry Enterprise Edition instance, you must configure this parameter.
| |
InstanceId | string | No | The ID of the Container Registry Enterprise Edition instance. | cri-nwj395hgf6f3**** |
RegionId | string | No | The region ID of the Container Registry Enterprise Edition instance. | cn-hangzhou |
ArnService | string | No | The Alibaba Cloud Resource Access (ARN) of the RAM role that is assigned to the user (the authorized account) in cross-account authorization scenarios. | acs:ram::1609982529******:role/role-test |
ArnUser | string | No | The ARN of the RAM role that is assigned to the authorizer in cross-account authorization scenarios. | acs:ram::1298452580******:role/role-test |
Arn | object | No | The details about the ARN that is required for authorization. | |
RoleArn | string | No | The ARN of the authorized role. | acs:ram:xxx |
RoleType | string | No | The authorization type. A value of service indicates that RAM roles are used for authorization. | user |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "CB8D2B22-D636-4182-****-1FC9DBDAD66F",
"TaskId": "t-bp18cwvrb3v9tjk0tekz"
}
Error codes
HTTP status code | Error code | Error message |
---|---|---|
400 | InvalidParameter | %s |
403 | InvalidVolumeType | The specified volumeName is invalid, only volume of cloud disk support capacity resize |
403 | IncorrectStatusDetail | %s |
403 | InvalidAction | The specified action is invalid |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2023-08-01 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2023-06-27 | The Error code has changed | View Change Details |
2023-03-30 | The Error code has changed | View Change Details |
2023-03-08 | The Error code has changed. The request parameters of the API has changed | View Change Details |