
Answer-first summary for fast verification
Answer: Use Cloud Build to include the release version tag in the application image.
To specify a particular version of your application for deployment based on the release version tagged in source control, the best practice is to include the release version tag in the application image itself. This can be achieved by using Cloud Build to embed the source control tag into the image during the build process. This method ensures that the image is directly associated with the source control tag, making it straightforward to deploy the correct version of the application. Option C suggests this approach, which is the correct answer. The other options either do not directly associate the image with the source control tag or suggest methods that are not as straightforward or reliable for this purpose.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
When building application images with Cloud Build and pushing them to Google Container Registry (GCR), how can you ensure the deployed image version corresponds to a specific release version tagged in source control? What steps should you take during the image push process?
A
Reference the image digest in the source control tag.
B
Supply the source control tag as a parameter within the image name.
C
Use Cloud Build to include the release version tag in the application image.
D
Use GCR digest versioning to match the image to the tag in source control.