Stay organized with collections
Save and categorize content based on your preferences.
This page shows you how to manually scale your worker pool.
Overview
Manual scaling lets you set a specific instance
count
without requiring redeployment.
This gives you the option to write your own
scaling logic using an external system. See the Kafka Autoscaler
for an example of this.
Billing considerations when using manual scaling
When you use manual scaling, all the instances that you requested are
billed as active instances, even if they happen to be idle.
For complete billing details, see the pricing page.
Required roles
To get the permissions that
you need to deploy Cloud Run worker pools,
ask your administrator to grant you the
following IAM roles:
If you are configuring a new worker pool, select Worker pools from the menu, and
click Deploy container. If you are
configuring an existing worker pool, click the worker pool to display its
detail pane, then click the pen icon next to Scaling at the top right
of the detail panel.
Locate the Scaling form (for a new worker pool) or the
Edit scaling form for an existing worker pool.
In the field labelled Number of instances, specify the number of container instances for the service.
Finish the specification.
Click Create for a new worker pool or Save for an existing worker pool.
gcloud
To specify scaling for a new worker pool, use the deploy
command:
INSTANCE_COUNT: the number of instances for the worker pool.
This sets the worker pool to manual scaling. Specify a value of 0 to disable
the worker pool.
IMAGE_URL: a reference to the container image that
contains the worker pool, such as us-docker.pkg.dev/cloudrun/container/worker-pool:latest.
Specify scaling for an existing worker pool by using the following
update command:
REGION: the Google Cloud region—for example,
europe-west1.
IMAGE_URL: a reference to the container image that
contains the worker pool, such as us-docker.pkg.dev/cloudrun/container/worker-pool:latest.
INSTANCE_COUNT: the number of instances for the worker pool.
This sets the worker pool to manual scaling. Specify a value of 0 to
disable the worker pool.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-25 UTC."],[],[],null,["# Manual scaling for worker pools\n\n| **Preview\n| --- Cloud Run manual scaling**\n|\n|\n| This feature is subject to the \"Pre-GA Offerings Terms\" in the General Service Terms section\n| of the [Service Specific Terms](/terms/service-terms#1).\n|\n| Pre-GA features are available \"as is\" and might have limited support.\n|\n| For more information, see the\n| [launch stage descriptions](/products#product-launch-stages).\n\nThis page shows you how to manually scale your worker pool.\n\nOverview\n--------\n\nManual scaling lets you set a specific instance\ncount\nwithout requiring redeployment.\nThis gives you the option to write your own\nscaling logic using an external system. See the [Kafka Autoscaler](/run/docs/configuring/workerpools/kafka-autoscaler)\nfor an example of this.\n\nBilling considerations when using manual scaling\n------------------------------------------------\n\nWhen you use manual scaling, all the instances that you requested are\nbilled as *active* instances, even if they happen to be idle.\nFor complete billing details, see the [pricing page](/run/pricing).\n\nRequired roles\n--------------\n\n\nTo get the permissions that\nyou need to deploy Cloud Run worker pools,\n\nask your administrator to grant you the\nfollowing IAM roles:\n\n- [Cloud Run Developer](/iam/docs/roles-permissions/run#run.developer) (`roles/run.developer`) on the Cloud Run service\n- [Service Account User](/iam/docs/roles-permissions/iam#iam.serviceAccountUser) (`roles/iam.serviceAccountUser`) on the service identity\n- [Artifact Registry Reader](/iam/docs/roles-permissions/artifactregistry#artifactregistry.reader) (`roles/artifactregistry.reader`) on the Artifact Registry repository of the deployed container image (if applicable)\n\n\nFor a list of IAM roles and permissions that are associated with\nCloud Run, see\n[Cloud Run IAM roles](/run/docs/reference/iam/roles)\nand [Cloud Run IAM permissions](/run/docs/reference/iam/permissions).\nIf your Cloud Run worker pool interfaces with\nGoogle Cloud APIs, such as Cloud Client Libraries, see the\n[service identity configuration guide](/run/docs/configuring/workerpools/service-identity).\nFor more information about granting roles, see\n[deployment permissions](/run/docs/reference/iam/roles#additional-configuration)\nand [manage access](/iam/docs/granting-changing-revoking-access).\n\nConfigure scaling\n-----------------\n\nChanging scaling mode or changing the manual instance count\ndoes not create a new revision.\n\nTo configure the scaling mode, use the Google Cloud console or the Google Cloud CLI: \n\n### Console\n\n1. In the Google Cloud console, go to Cloud Run:\n\n [Go to Cloud Run](https://console.cloud.google.com/run/worker-pools)\n2. If you are configuring a new worker pool, select **Worker pools** from the menu, and\n click **Deploy container** . If you are\n configuring an existing worker pool, click the worker pool to display its\n detail pane, then click the pen icon next to **Scaling** at the top right\n of the detail panel.\n\n3. Locate the **Scaling** form (for a new worker pool) or the\n **Edit scaling** form for an existing worker pool.\n\n4. In the field labelled **Number of instances**, specify the number of container instances for the service.\n\n5. Finish the specification.\n\n6. Click **Create** for a new worker pool or **Save** for an existing worker pool.\n\n### gcloud\n\n\nTo specify scaling for a new worker pool, use the [deploy](/sdk/gcloud/reference/beta/run/worker-pools/deploy)\ncommand: \n\n```bash\ngcloud beta run worker-pools deploy WORKER_POOL \\\n --scaling=INSTANCE_COUNT \\\n --image IMAGE_URL\n```\n\nReplace the following:\n\n- \u003cvar translate=\"no\"\u003eWORKER_POOL\u003c/var\u003e: the name of your worker pool.\n- \u003cvar translate=\"no\"\u003eINSTANCE_COUNT\u003c/var\u003e: the number of instances for the worker pool. This sets the worker pool to manual scaling. Specify a value of `0` to disable the worker pool.\n- \u003cvar translate=\"no\"\u003eIMAGE_URL\u003c/var\u003e: a reference to the container image that contains the worker pool, such as `us-docker.pkg.dev/cloudrun/container/worker-pool:latest`.\n\nSpecify scaling for an existing worker pool by using the following\n[update](/sdk/gcloud/reference/beta/run/worker-pools/update) command: \n\n```bash\ngcloud beta run worker-pools update WORKER_POOL \\\n --scaling=INSTANCE_COUNT\n```\n\n### Terraform\n\n\u003cbr /\u003e\n\nTo learn how to apply or remove a Terraform configuration, see\n[Basic Terraform commands](/docs/terraform/basic-commands).\n\n\u003cbr /\u003e\n\n resource \"google_cloud_run_v2_worker_pool\" \"default\" {\n name = \"\u003cvar translate=\"no\"\u003eWORKER_POOL\u003c/var\u003e\"\n location = \"\u003cvar translate=\"no\"\u003eREGION\u003c/var\u003e\"\n launch_stage = \"BETA\"\n\n template {\n containers {\n image = \"\u003cvar translate=\"no\"\u003eIMAGE_URL\u003c/var\u003e\"\n }\n }\n scaling {\n scaling_mode = \"MANUAL\"\n manual_instance_count = \"\u003cvar translate=\"no\"\u003eINSTANCE_COUNT\u003c/var\u003e\"\n }\n }\n\nReplace the following:\n\n- \u003cvar translate=\"no\"\u003eWORKER_POOL\u003c/var\u003e: the name of the worker pool.\n- \u003cvar translate=\"no\"\u003eREGION\u003c/var\u003e: the Google Cloud region---for example, `europe-west1`.\n- \u003cvar translate=\"no\"\u003eIMAGE_URL\u003c/var\u003e: a reference to the container image that contains the worker pool, such as `us-docker.pkg.dev/cloudrun/container/worker-pool:latest`.\n- \u003cvar translate=\"no\"\u003eINSTANCE_COUNT\u003c/var\u003e: the number of instances for the worker pool. This sets the worker pool to manual scaling. Specify a value of `0` to disable the worker pool.\n\nView scaling configuration for a worker pool\n--------------------------------------------\n\n1. In the Google Cloud console, go to Cloud Run:\n\n [Go to Cloud Run](https://console.cloud.google.com/run/worker-pools)\n2. Click **Worker pools** to display the list of deployed worker pools.\n\n3. Click the worker pool you want to examine to display its details pane.\n\n4. The current scaling setting is shown above the worker pools revision list:\n **Scaling: Manual (Instances: )**.\n\n| **Note:** You can also use the Google Cloud CLI command [`gcloud beta run worker-pools describe`](/sdk/gcloud/reference/beta/run/worker-pools/describe) to view configuration details.\n\nDisable a worker pool\n---------------------\n\nTo disable a worker pool, use the following command to set scaling to zero: \n\n```bash\ngcloud beta run worker-pools update WORKER_POOL --scaling=0\n```\n\nReplace \u003cvar translate=\"no\"\u003eWORKER_POOL\u003c/var\u003e with the name of your worker pool."]]