Skip to main content

Managing your spending limit for GitHub Actions

You can set a spending limit for GitHub Actions usage.

About spending limits for GitHub Actions

公共存储库中标准 GitHub 托管的运行器和自托管运行器可免费使用 GitHub Actions。 对于专用存储库,每个 GitHub 帐户可获得一定数量的免费时间和存储以用于 GitHub 托管的运行器,具体取决于帐户的计划。 超出包含数量的任何使用量都由支出限制控制。

如果您是按月计费的客户,您的帐户默认支出限额将为 0 美元,这可防止私有仓库超出帐户中所含金额的额外使用分钟数或存储空间。 如果按发票支付帐户费用,则帐户将具有无限制的默认支出限制。

您可以设置特定的支出限额,或者对某些帐户允许无限制的支出。 支出限制适用于 GitHub Packages 和 GitHub Actions 的组合超额(任何超出计划额度的使用量)。 For more information about pricing for GitHub Actions usage, see "About billing for GitHub Actions."

If you are an organization owner, you can connect an Azure Subscription ID to your organization account to enable and pay for GitHub Actions usage beyond the amounts including with your account. For more information, see "连接 Azure 订阅."

As soon as you set a spending limit other than $0, you will be responsible for any existing overages in the current billing period. For example, if your organization uses GitHub Team, does not allow overages, and creates workflow artifacts that increase your storage usage for the month from 1.9GB to 2.1GB, you will use slightly more storage than the 2GB your product includes.

Because you have not enabled overages, your next attempt to create a workflow artifact will fail. You will not receive a bill for the 0.1GB overage that month. However, if you enable overages, your first bill will include the 0.1GB of existing overage for the current billing cycle, as well as any additional overages you accrue.

Managing the spending limit for GitHub Actions for your personal account

Anyone can manage the spending limit for GitHub Actions for their own personal account.

  1. 在 GitHub 任意页的右上角,单击个人资料照片,然后单击“设置”。

  2. 在侧边栏的“访问”部分,单击“ 计费和计划”,然后单击“支出限制” 。

  3. 在页面顶部的“付款信息”下,单击“管理支出限制”。

    “账单设置”页的“摘要”部分的屏幕截图。 右侧以深橙色边框突出显示了“管理支出限制”。

  4. 在“操作和包”下,选择限制支出或允许无限制支出。

  5. 根据选择的选项,单击“更新限制”或“更新为无限制”。

Managing the spending limit for GitHub Actions for your organization

Organizations owners and billing managers can manage the spending limit for GitHub Actions for an organization.

  1. 在 GitHub 任意页的右上角,单击个人资料照片,然后单击“设置”。

  2. 在边栏的“访问”部分中,单击“ 组织”。

  3. 在组织旁边,单击“设置”。

  4. 如果你是组织所有者,请在侧边栏的“访问”部分,单击“ 计费和计划”。

  5. 在页面顶部的“付款信息”下,单击“管理支出限制”。

    “账单设置”页的“摘要”部分的屏幕截图。 右侧以深橙色边框突出显示了“管理支出限制”。

  6. Under "Monthly spending limit", choose to limit spending or allow unlimited spending.

    Note: If GitHub Codespaces is enabled for your organization, scroll to "Actions & Packages", then choose to limit spending or allow unlimited spending.

  7. 根据选择的选项,单击“更新限制”或“更新为无限制”。

Managing usage and spending limit email notifications

当支出达到帐户包含使用量的 75%、90% 和 100% 以及支出达到帐户支出限制的 75%、90% 和 100% 时,系统将向帐户所有者和计费管理员发送电子邮件通知。

可以随时通过导航到“支出限制”页底部的“电子邮件警报”部分来禁用这些通知。