Topic 1 Question 110
Your company is using HTTPS requests to trigger a public Cloud Run-hosted service accessible at the https://booking-engine-abcdef.a.run.app URL. You need to give developers the ability to test the latest revisions of the service before the service is exposed to customers. What should you do?
Run the gcloud run deploy booking-engine --no-traffic --tag dev command. Use the https://dev--booking-engine-abcdef.a.run.app URL for testing.
Run the gcloud run services update-traffic booking-engine --to-revisions LATEST=1 command. Use the https://booking-engine-abcdef.a.run.app URL for testing.
Pass the curl –H “Authorization:Bearer $(gcloud auth print-identity-token)” auth token. Use the https://booking-engine-abcdef.a.run.app URL to test privately.
Grant the roles/run.invoker role to the developers testing the booking-engine service. Use the https://booking-engine-abcdef.private.run.app URL for testing.
ユーザの投票
コメント(4)
- 正解だと思う選択肢: A
A, as it is possible to accept a tagged revision as explained here: https://cloud.google.com/run/docs/rollouts-rollbacks-traffic-migration#deploy-with-tags
👍 6florian_cartron2023/10/09 - 正解だと思う選択肢: A
It create a new deployment(revision) with no traffic to https://booking-engine-abcdef.a.run.app but the revision can be tested by developer at https://dev--booking-engine-abcdef.a.run.app as dev tag is associated with the deploymnet.
Reference: https://cloud.google.com/sdk/gcloud/reference/run/deploy
👍 4PrayasMohanty2023/10/10 - 正解だと思う選択肢: A
To enable developers to test the latest revisions of a Cloud Run-hosted service before exposing it to customers, the recommended approach is to use the --no-traffic flag during deployment, as outlined in (Option A).
By running the command gcloud run deploy booking-engine --no-traffic --tag dev, you deploy the service with no traffic routed to it initially. Subsequently, developers can test the latest revisions using the URL https://dev--booking-engine-abcdef.a.run.app. This allows for a controlled and private testing environment where developers can validate the service's functionality and behavior before making it publicly accessible. Utilizing a dedicated URL with the --tag option ensures that developers can interact with the specific version intended for testing, facilitating a smooth and secure testing process.
👍 2xhilmi2023/12/06
シャッフルモード