共用数据结构
Namespace
命名空间资源对象。
| 字段 | 类型 | 描述 |
|---|
| id | string | 命名空间 ID,格式 subscriptions/{subscription_name}/resourceGroups/{resource_group_name}/zones/{zone}/namespaces/{namespace_name}(只读) |
| name | string | 命名空间名称,约束 ^[a-z0-9]+(?:[._-][a-z0-9]+)*$(只读) |
| display_name | string | 命名空间显示名称,最大 63 字符 |
| description | string | 命名空间描述 |
| uid | string | 命名空间 UID(只读) |
| resource_type | string | 资源类型,例如 ccr.namespace |
| creator_id | string | 创建者 ID(只读) |
| owner_id | string | 拥有者 ID(只读) |
| tenant_id | string | 租户 ID(只读) |
| zone | string | 资源所属可用区(只读) |
| state | string | 命名空间状态,见 Namespace.State 枚举(只读) |
| sku_id | string | 最小库存单元 ID |
| tags | map[string]string | 标签(只读) |
| properties | object(NamespaceProperties) | 命名空间属性 |
| order_info | object(OrderInfo) | 订单信息(只读) |
| deleted | boolean | 是否已删除(只读) |
| create_time | string(date-time) | 创建时间(只读) |
| update_time | string(date-time) | 最后更新时间(只读) |
Namespace.State 枚举
| 值 | 描述 |
|---|
| CREATING | 创建中 |
| UPDATING | 更新中 |
| ACTIVE | 已激活 |
| DELETING | 删除中 |
| DELETED | 已删除 |
| FAILED | 操作失败 |
| EXPIRESTOPPING | 到期停服中 |
| EXPIRESTOPPED | 到期已停服 |
| RENEWSTARTING | 续订恢复中 |
| EXPIREDOWNGRADE | 到期降级中 |
| RESIZING | 资源变更中 |
| RESIZECANCELING | 取消资源变更 |
NamespaceProperties
命名空间属性。
Resources
资源规格属性。
| 字段 | 类型 | 必须 | 描述 |
|---|
| billing_items | object(BillingItems) | 是 | 独立购买的计费项 |
| access_level | boolean | 是 | 命名空间访问权限:true = 公开,false = 私有 |
BillingItems
命名空间计费项。
| 字段 | 类型 | 必须 | 描述 |
|---|
| capacity | int32 | 是 | 容量数值 |
| capacity_unit | string | 是 | 容量单位,取值:EB / PB / TB / GB / MB |
Repository
镜像仓库对象。
| 字段 | 类型 | 描述 |
|---|
| id | int32 | 仓库 ID(只读) |
| name | string | 仓库名称(只读) |
| description | string | 仓库描述(只读) |
| project_id | int32 | 所属项目 ID(只读) |
| artifact_count | int32 | 镜像制品数量(只读) |
| pull_count | int32 | 镜像拉取次数(只读) |
| tag_count | int32 | 标签数量(只读) |
| tags | array[string] | 标签名列表(只读) |
| metadata | object(Metadata) | 元数据 |
| domain | string | 镜像所在域名(只读) |
| creation_time | string(date-time) | 创建时间(只读) |
| update_time | string(date-time) | 最后更新时间(只读) |
Artifact
镜像制品对象。
| 字段 | 类型 | 描述 |
|---|
| id | string | 制品 ID |
| digest | string | 制品摘要 |
| manifest_media_type | string | 制品清单的媒体类型 |
| media_type | string | 制品的媒体类型 |
| project_id | string | 所属项目 ID |
| repository_id | string | 所属镜像仓库 ID |
| size | string | 制品大小(字节) |
| type | string | 制品类型,例:image、chart |
| tags | array(Tag) | 标签列表 |
| pull_time | string(date-time) | 最后一次拉取时间(只读) |
| push_time | string(date-time) | 推送时间(只读) |
Tag
标签对象。
| 字段 | 类型 | 描述 |
|---|
| id | string | 标签 ID |
| name | string | 标签名称 |
| artifact_id | string | 所附镜像制品 ID |
| immutable | boolean | 是否不可更改 |
| pull_time | string(date-time) | 最后一次拉取时间(只读) |
| push_time | string(date-time) | 推送时间(只读) |
仓库元数据信息。
| 字段 | 类型 | 描述 |
|---|
| products | array[string] | 产品类别 |
| chips | array[string] | 芯片类别 |
| labels | map[string]string | 标签 |
| source | string | 源,例如 local |
OfficialRepository
官方镜像仓库对象。字段与 Repository 基本一致,不含 tags 字段。
| 字段 | 类型 | 描述 |
|---|
| id | int32 | 仓库 ID(只读) |
| name | string | 仓库名称(只读) |
| description | string | 仓库描述(只读) |
| project_id | int32 | 所属项目 ID(只读) |
| artifact_count | int32 | 镜像制品数量(只读) |
| pull_count | int32 | 镜像拉取次数(只读) |
| metadata | object(Metadata) | 元数据 |
| domain | string | 镜像所在域名(只读) |
| creation_time | string(date-time) | 创建时间(只读) |
| update_time | string(date-time) | 最后更新时间(只读) |