{"id":24233194,"url":"https://github.com/memes/terraform-google-cloudbuild","last_synced_at":"2025-03-04T13:25:33.472Z","repository":{"id":37983818,"uuid":"457152395","full_name":"memes/terraform-google-cloudbuild","owner":"memes","description":"Helper module to setup various Cloud Build triggers","archived":false,"fork":false,"pushed_at":"2025-01-13T04:16:06.000Z","size":188,"stargazers_count":5,"open_issues_count":3,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-14T16:15:33.637Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/memes.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-02-09T00:31:00.000Z","updated_at":"2024-12-27T19:56:47.000Z","dependencies_parsed_at":"2023-02-10T01:15:51.285Z","dependency_job_id":"3fcfbb9b-d32e-4cbf-8bfa-e4471ff73630","html_url":"https://github.com/memes/terraform-google-cloudbuild","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":"memes/repo-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/memes%2Fterraform-google-cloudbuild","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/memes%2Fterraform-google-cloudbuild/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/memes%2Fterraform-google-cloudbuild/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/memes%2Fterraform-google-cloudbuild/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/memes","download_url":"https://codeload.github.com/memes/terraform-google-cloudbuild/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241853949,"owners_count":20031334,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-01-14T16:00:41.999Z","updated_at":"2025-03-04T13:25:33.448Z","avatar_url":"https://github.com/memes.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Google Cloud Build module for Terraform\n\n![GitHub release](https://img.shields.io/github/v/release/memes/terraform-google-cloudbuild?sort=semver)\n![Maintenance](https://img.shields.io/maintenance/yes/2024)\n[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](CODE_OF_CONDUCT.md)\n\nGoogle Cloud Build offers a variety of different ways to implement a GitOps-like\ntrigger, with support for many commercial Git hosting providers. The purpose of\nthese modules is to make it easier to create a Cloud Build trigger for common\ntrigger scenarios; e.g. a GitHub App trigger, a GSR trigger, etc.\n\nWhile it is possible to use this root module directly, the scenario specific\nsubmodules have additional validation to make it easier to provision a suitable\ntrigger without running afoul of the full Cloud Build trigger constraints. To\nreinforce this, all examples use a scenario module.\n\n\u003e TL;DR - PREFER TO USE THE SCENARIO SPECIFIC SUBMODULE FOR YOUR TRIGGER!\n\n## Scenario modules\n\n* [GitHub](modules/github/)\n\n    Use this module to add a Cloud Build trigger for source that is hosted in\n    GitHub (or GitHub Enterprise), and the Cloud Build app for GitHub is\n    authorized to access the repository. An alternative is to allow GCP to mirror\n    the source to a GSR and use the [Google Source](modules/google-source-repo)\n    module instead.\n\n* [Google Source Repository](modules/google-source-repo/)\n\n    Use this module to add a Cloud Build trigger that reacts to changes in\n    GSR. This includes cases where source from an external repository is being\n    mirrored into GSR (e.g. from BitBucket, GitLab, or an existing GitHub mirrored\n    repository).\n\n## Contributing\n\nSee [CONTRIBUTING](CONTRIBUTING.md) for guidelines.\n\n\u003c!-- markdownlint-disable no-inline-html no-bare-urls --\u003e\n\u003c!-- BEGINNING OF PRE-COMMIT-TERRAFORM DOCS HOOK --\u003e\n## Requirements\n\n| Name | Version |\n|------|---------|\n| \u003ca name=\"requirement_terraform\"\u003e\u003c/a\u003e [terraform](#requirement\\_terraform) | \u003e= 0.14.5 |\n| \u003ca name=\"requirement_google\"\u003e\u003c/a\u003e [google](#requirement\\_google) | \u003e= 4.36.0 |\n\n## Modules\n\nNo modules.\n\n## Resources\n\n| Name | Type |\n|------|------|\n| [google_cloudbuild_trigger.trigger](https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/cloudbuild_trigger) | resource |\n| [google_service_account.sa](https://registry.terraform.io/providers/hashicorp/google/latest/docs/data-sources/service_account) | data source |\n\n## Inputs\n\n| Name | Description | Type | Default | Required |\n|------|-------------|------|---------|:--------:|\n| \u003ca name=\"input_name\"\u003e\u003c/a\u003e [name](#input\\_name) | The name to give to the Cloud Build trigger. | `string` | n/a | yes |\n| \u003ca name=\"input_project_id\"\u003e\u003c/a\u003e [project\\_id](#input\\_project\\_id) | The GCP project id where the Cloud Build trigger will be installed. | `string` | n/a | yes |\n| \u003ca name=\"input_trigger_config\"\u003e\u003c/a\u003e [trigger\\_config](#input\\_trigger\\_config) | The trigger\\_config variable defines the type of trigger (GitHub, GSR, etc), and\u003cbr\u003ethe specific configuration options needed. The combination of fields is too\u003cbr\u003ecomplex to validate effectively, use a scenario specific submodule which hides\u003cbr\u003ethis complexity! | \u003cpre\u003eobject({\u003cbr\u003e    gsr = object({\u003cbr\u003e      project_id   = string\u003cbr\u003e      name         = string\u003cbr\u003e      branch_regex = string\u003cbr\u003e      tag_regex    = string\u003cbr\u003e    })\u003cbr\u003e    github = object({\u003cbr\u003e      owner           = string\u003cbr\u003e      name            = string\u003cbr\u003e      branch_regex    = string\u003cbr\u003e      tag_regex       = string\u003cbr\u003e      is_pr_trigger   = bool\u003cbr\u003e      comment_control = string\u003cbr\u003e    })\u003cbr\u003e    pubsub = object({\u003cbr\u003e      topic                 = string\u003cbr\u003e      service_account_email = string\u003cbr\u003e    })\u003cbr\u003e    webhook = object({\u003cbr\u003e      secret = string\u003cbr\u003e    })\u003cbr\u003e  })\u003c/pre\u003e | n/a | yes |\n| \u003ca name=\"input_description\"\u003e\u003c/a\u003e [description](#input\\_description) | An optional description to apply to the Cloud Build trigger. | `string` | `\"\"` | no |\n| \u003ca name=\"input_dir\"\u003e\u003c/a\u003e [dir](#input\\_dir) | The directory path, relative to repository root, where the Cloud Build run will\u003cbr\u003ebe executed. Default is an empty string. | `string` | `\"\"` | no |\n| \u003ca name=\"input_disabled\"\u003e\u003c/a\u003e [disabled](#input\\_disabled) | A flag to create/modify the Cloud Build trigger into a disabled state. | `bool` | `false` | no |\n| \u003ca name=\"input_filename\"\u003e\u003c/a\u003e [filename](#input\\_filename) | The path, relative to repository root, to the Cloud Build YAML file. The default\u003cbr\u003econfiguration will declare the filename 'cloudbuild.yml'. | `string` | `\"cloudbuild.yml\"` | no |\n| \u003ca name=\"input_ignored_files\"\u003e\u003c/a\u003e [ignored\\_files](#input\\_ignored\\_files) | An optional set of file globs to ignore when determining the set of source\u003cbr\u003echanges. If provided, the list of changed files will be filtered through this\u003cbr\u003elist of globs, and the trigger action will proceed only if there are unfiltered\u003cbr\u003efiles remaining. Default is an empty list, meaning any changes in repo should\u003cbr\u003etrigger the action, subject to `included_files`. | `list(string)` | `[]` | no |\n| \u003ca name=\"input_included_files\"\u003e\u003c/a\u003e [included\\_files](#input\\_included\\_files) | An optional set of file globs to explicitly match when determining the set of\u003cbr\u003esource changes. If provided, the list of changed files will be filtered through this\u003cbr\u003elist of globs, and the trigger action will proceed only if there are positive\u003cbr\u003ematches. Default is an empty list, meaning any changes in repo should\u003cbr\u003etrigger the action, subject to `ignored_files`. | `list(string)` | `[]` | no |\n| \u003ca name=\"input_invert_regex\"\u003e\u003c/a\u003e [invert\\_regex](#input\\_invert\\_regex) | If set, the tag or branch regular expressions used to match GitHub events will\u003cbr\u003ebe effectively inverted, and events that *do not match* the tag or branch pattern\u003cbr\u003ewill be executed. Default is false. | `bool` | `false` | no |\n| \u003ca name=\"input_location\"\u003e\u003c/a\u003e [location](#input\\_location) | Specifies the location of the Cloud Build pool to use for the triggered workload.\u003cbr\u003eThe default value is 'global', but any supported Cloud Build location may be used. | `string` | `\"global\"` | no |\n| \u003ca name=\"input_service_account\"\u003e\u003c/a\u003e [service\\_account](#input\\_service\\_account) | An optional way to override the service account used by Cloud Build. If left\u003cbr\u003eempty (default), the standard Cloud Build service account for project specified\u003cbr\u003ein `project_id` will be used during execution. | `string` | `\"\"` | no |\n| \u003ca name=\"input_substitutions\"\u003e\u003c/a\u003e [substitutions](#input\\_substitutions) | A map of substitution key:value pairs that can be referenced in the build\u003cbr\u003edefinition. Default is empty. | `map(string)` | `{}` | no |\n| \u003ca name=\"input_tags\"\u003e\u003c/a\u003e [tags](#input\\_tags) | An optional set of tags to annotate the Cloud Build trigger. | `set(string)` | `[]` | no |\n\n## Outputs\n\n| Name | Description |\n|------|-------------|\n| \u003ca name=\"output_id\"\u003e\u003c/a\u003e [id](#output\\_id) | The fully-qualified identifier of the created Cloud Build trigger. |\n| \u003ca name=\"output_trigger_id\"\u003e\u003c/a\u003e [trigger\\_id](#output\\_trigger\\_id) | The project-local identifier of the created Cloud Build trigger. |\n\u003c!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK --\u003e\n\u003c!-- markdownlint-enable no-inline-html no-bare-urls --\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmemes%2Fterraform-google-cloudbuild","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmemes%2Fterraform-google-cloudbuild","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmemes%2Fterraform-google-cloudbuild/lists"}