11.4.5. 使用配额限制拒绝推送


如果镜像推送超过定义的配额限制,则会出现软或硬检查:

  • 对于软检查,或警告,用户会收到通知。
  • 对于硬检查 或拒绝,推送将被终止。

11.4.5.1. 设置 reject 和 warning 限制

要设置 rejectwarning 限制,POST 数据到 /api/v1/organization/{orgname}/quota/{quota_id}/limit 端点:

reject limit 命令示例

$ curl -k -X POST -H "Authorization: Bearer <token>" -H 'Content-Type: application/json' -d '{"type":"Reject","threshold_percent":80}'  https://example-registry-quay-quay-enterprise.apps.docs.gcp.quaydev.org/api/v1/organization/testorg/quota/1/limit

警告限制命令示例

$ curl -k -X POST -H "Authorization: Bearer <token>" -H 'Content-Type: application/json' -d '{"type":"Warning","threshold_percent":50}'  https://example-registry-quay-quay-enterprise.apps.docs.gcp.quaydev.org/api/v1/organization/testorg/quota/1/limit

Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

关于红帽文档

Legal Notice

Theme

© 2026 Red Hat
返回顶部