Container Registry API, REST: LifecyclePolicy.get
Returns the specified lifecycle policy.
To get the list of all available lifecycle policies, make a list request.
HTTP request
GET https://container-registry.api.il.nebius.cloud/container-registry/v1/lifecyclePolicies/{lifecyclePolicyId}
Path parameters
Parameter | Description |
---|---|
lifecyclePolicyId | Required. ID of the lifecycle policy. The maximum string length in characters is 50. |
Response
HTTP Code: 200 - OK
{
"id": "string",
"name": "string",
"repositoryId": "string",
"description": "string",
"status": "string",
"createdAt": "string",
"rules": [
{
"description": "string",
"expirePeriod": "string",
"tagRegexp": "string",
"untagged": true,
"retainedTop": "string"
}
]
}
Field | Description |
---|---|
id | string ID of the lifecycle policy. |
name | string Name of the lifecycle policy. |
repositoryId | string ID of the repository that the lifecycle policy belongs to. Required. The maximum string length in characters is 50. |
description | string Description of the lifecycle policy. The maximum string length in characters is 256. |
status | string Status of lifecycle policy.
|
createdAt | string (date-time) Creation timestamp. String in RFC3339 text format. The range of possible values is from To work with values in this field, use the APIs described in the Protocol Buffers reference. In some languages, built-in datetime utilities do not support nanosecond precision (9 digits). |
rules[] | object The rules of lifecycle policy. |
rules[]. description |
string Description of the lifecycle policy rule. The maximum string length in characters is 256. |
rules[]. expirePeriod |
string Period of time for automatic deletion. Period must be a multiple of 24 hours. The minimum value is 86400 seconds. |
rules[]. tagRegexp |
string Tag for specifying a filter in the form of a regular expression. The maximum string length in characters is 256. |
rules[]. untagged |
boolean (boolean) Tag for applying the rule to Docker images without tags. |
rules[]. retainedTop |
string (int64) Number of Docker images (falling under the specified filter by tags) that must be left, even if the expire_period has already expired. The minimum value is 0. |