What command should you run to deploy a new version of a Cloud Run service without routing traffic to it?

Study for the Google Cloud DevOps Certification Test. Prepare with interactive quizzes and detailed explanations. Enhance your skills and boost your confidence!

To deploy a new version of a Cloud Run service without routing traffic to it, the command that should be executed is indeed the one that specifies the --no-traffic flag. This flag prevents any existing traffic from being routed to the newly deployed revision of the service until you explicitly decide to do so later.

When you run gcloud run deploy booking-engine --no-traffic --tag dev, the deployment proceeds, creating a new revision tagged as "dev," but it ensures that none of the incoming traffic is directed to this revision right away. This is particularly useful in scenarios where you want to test the deployment before making it live, allowing for validation without impacting users with untested changes.

The other choices provided do not align with the requirement of deploying a service without routing traffic to it. Adjusting traffic or authorization settings does not accomplish the goal of initially routing no traffic to the new version.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy