Prerequisites
Pricing policies are project-level resources:- To view pricing policies, make sure you are in a group with at least the
viewerrole within the project. - To create, edit or delete pricing policies, make sure you are in a group with at least the
editorrole within the project.
How to view pricing policies
- Web console
- CLI
- In the web console, go to Billing → Pricing.
- Switch to the Pricing policy tab and find the policy that you need. If the policy status is Blocked, its max price is lower than the current spot price. Resources that use this policy can’t start until the spot price decreases or until you increase the max price.
How to create a pricing policy
You can create a pricing policy before creating preemptible resources, or create it while configuring a new resource in the web console.- Web console
- CLI
- In the web console, go to Billing → Pricing.
- Switch to the Pricing policy tab and click Create pricing policy.
- Enter a policy name.
- Select the project where the policy will be available.
- Select the GPU platform for the policy.
- In Max price, enter the highest spot price per GPU hour at which preemptible resources can run on this platform. The web console shows the allowed price range. To let resources start while the current spot price stays unchanged, enter a value that is higher than or equal to the current spot price.
- Click Create pricing policy.
How to edit a pricing policy
To update the max price in a pricing policy, first stop all running resources that use that policy.
- Web console
- CLI
- In the web console, go to Billing → Pricing.
- Switch to the Pricing policy tab.
- Find the policy you want to edit and click → Edit.
- Rename the policy or adjust the max price.
- Click Save changes.
How to delete a pricing policy
- Web console
- CLI
- In the web console, go to Billing → Pricing.
- Switch to the Pricing policy tab.
- Check the number of running resources that use the policy.
- Find the policy you want to delete and click → Delete. If the web console shows affected resources, review them and continue only if they can be stopped.
- Enter the policy name and click Delete policy.