repository
dwp/repository/github
Terraform module to manage GitHub repositories
GitHub Repository Terraform Module Terraform module to manage GitHub repositories Requirements - Terraform 0.14 - GitHub personal access token with the following permissions: - admin:repo_hook, delete_repo, read:org, read:user, repo - A GitHub organisation or user Usage For a GitHub organisation ``hcl module "my_repo" { source = "dwp/repository/github" name = "my-repo" } ` For a GitHub user `hcl module "my_repo" { source = "dwp/repository/github" name = "my-repo" branch_protection_enabled = false } ` Example `hcl variable "github_organization" { type = string description = "GitHub Organisation to create repos in" default = "dwp" } variable "github_token" { type = string description = "GitHub personal access token for managing repos" } provider "github" { token = var.github_token organizati
| Name | Type | Description | Default |
|---|---|---|---|
| name | string | Name of the repository. Can only contain lowercase letters, numbers, and hyphens | required |
| auto_init | bool | (Optional) Meaningful only during create, set to true to produce an initial comm | true |
| topics | list(string) | (Optional) A list of GitHub topics to add to this repository | [
"govuk",
"hacktoberfest"
] |
| branch_protection_enabled | bool | (Optional) Control branch protection for the default branch | true |
| enforce_admins | bool | (Optional) Enforce status checks for repository administrators | true |
| require_status_checks | bool | (Optional) Require all status checks listed in status_checks to pass | true |
| has_downloads | bool | (Optional) Enables GitHub issues | false |
| is_template | bool | (Optional) Tells GitHub it's a template repository | false |
| allow_merge_commit | bool | (Optional) Set to `false` to disable merge commits on the repository | false |
| status_checks | list(any) | (Optional) A list of required passing CI checks | [] |
| dismiss_stale_reviews | bool | (Optional) Dismiss approved reviews automatically when a new commit is pushed | true |
| require_code_owner_reviews | bool | (Optional) Require an approved review in pull requests including files with a de | false |
| required_approving_review_count | number | (Optional) Require x number of approvals to satisfy branch protection requiremen | 1 |
| homepage_url | string | (Optional) Home page URL for the Git repo | "" |
| has_issues | bool | (Optional) Enables GitHub issues | true |
| has_wiki | bool | (Optional) Enables GitHub wiki | false |
| template | object({ owner = string | (Optional) Use a template repository to create this repository | {
"owner": "",
"repo": ""
} |
| team_access | map(object({ team_id = str | A map of access to the repository | {} |
| allow_rebase_merge | bool | (Optional) Set to `false` to disable rebase merges on the repository | true |
| labels | map(object({ name = | (Optional) A map of labels to add to this repository | {
"invalid": {
"color_hex": "00000 |
| delete_branch_on_merge | bool | (Optional) Automatically delete head branch after a pull request is merged | true |
A batteries included cloud-init config to quickly and easily deploy a single Doc
Terraform module to create VPC resource on AWS.
Terraform module to create default S3 bucket with logging and encryption type sp
This terraform module is used to create ECR on AWS.