
Answer-first summary for fast verification
Answer: Connect to an external repository in Cloud Source Repository. Authorize Google Cloud Platform to connect to the GitHub repository. Create a trigger in Cloud Build to automate the image creation., Commit code to the repository in GitHub.
To minimize overhead, connecting to an external repository like GitHub in Cloud Source Repository (CSR) and authorizing Google Cloud Platform to access the GitHub repository is efficient. This setup allows code commits to GitHub to be mirrored in CSR, triggering Cloud Build automatically. Options C and D introduce unnecessary steps such as creating a new repository or granting permissions that Cloud Build doesn't require for image building. References: [Mirroring a GitHub repository](https://cloud.google.com/source-repositories/docs/mirroring-a-github-repository), [Integrating with Cloud Build](https://cloud.google.com/source-repositories/docs/integrating-with-cloud-build).
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
Your organization is transitioning its applications to the Cloud and currently uses GitHub for source code version control. You're tasked with setting up a proof-of-concept deployment that links GitHub to Cloud Build for image creation and deployment. Which two steps would minimize overhead in achieving this?
A
Commit code to the repository in GitHub.
B
Connect to an external repository in Cloud Source Repository. Authorize Google Cloud Platform to connect to the GitHub repository. Create a trigger in Cloud Build to automate the image creation.
C
Create a new repository in Cloud Source Repository. Create a trigger in Cloud Build to automate the image creation. Clone the GitHub repository.
D
Grant the Cloud Build service account the permissions to build the image.
E
Commit code to the new repository in Cloud Source Repository.
No comments yet.