Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support using a customer service account to run Cloud Build triggers in the cicd recipe #1031

Closed
xingao267 opened this issue Sep 15, 2021 · 2 comments · Fixed by #1034
Closed
Assignees
Labels
cicd CICD templates related in Terraform Engine engine enhancement New feature or request P1

Comments

@xingao267
Copy link
Member

xingao267 commented Sep 15, 2021

The work needs to be done are roughly

  1. Follow this and add necessary resources to our cicd recipe, which includes a new logging bucket, an optional service account (either passed in or created in our recipe, toggled by an input param). The service account will later be used in google_cloudbuild_trigger resources.

  2. The feature to use a custom SA in cloud build triggers are still in beta, and Terraform's google beta provider does not seem to support that yet. See pending issue. The code to support that likely should be added here. We can help implement that. Terraform provider has a weekly release schedule. Once the change is approved and merged, it might take 1-2 weeks for it to be available, so need to plan accordingly.

Note: the cloud build's doc suggests that feature is still in beta, but in that issue in terraform provider repo, someone suggests that it's already GA. This is something to look into a bit more and verify.

  1. Change the google_cloudbuild_trigger resources in cicd recipe to use the service account. If need to switch to beta provider, we should add google-beta in the resource's provider field. The cloudbuild yaml file should be modified to use the custom logging bucket as well.

  2. Test, add docs for upgrade instructions, etc.

@xingao267 xingao267 added cicd CICD templates related in Terraform Engine engine enhancement New feature or request P1 labels Sep 15, 2021
@pasha-gh
Copy link
Contributor

PR #5237 for adding the service_account field to google_cloudbuild_trigger in the provider merged.

@pasha-gh
Copy link
Contributor

pasha-gh commented Oct 6, 2021

#1034

@pasha-gh pasha-gh closed this as completed Oct 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cicd CICD templates related in Terraform Engine engine enhancement New feature or request P1
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants