diff --git a/README.md b/README.md index d93fc7c..bf965f4 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Terraform GitHub Repository Module -A comprehensive Terraform module for managing GitHub repositories with advanced features like branch protection, file management, and team access control. You can use this module to create new repositories or manage existing ones. +A comprehensive Terraform module for managing GitHub repositories with advanced features like branch protection, file management, team access control, and deployment keys. You can use this module to create new repositories or manage existing ones. ## Features - Create new repositories or manage existing ones @@ -10,6 +10,7 @@ A comprehensive Terraform module for managing GitHub repositories with advanced - Team access configuration - Action secrets management - Repository collaborator management +- Deploy key management - Automated README generation - Issue management @@ -97,6 +98,30 @@ module "managed_repo" { } ``` +### Repository with Deploy Keys + +```hcl +module "repo_with_deploy_keys" { + source = "HappyPathway/repo/github" + + name = "my-project-with-deploy-keys" + repo_org = "MyOrganization" + + deploy_keys = [ + { + title = "CI Server Key" + key = "ssh-rsa AAAAB3NzaC1yc2EAAA..." + read_only = true # Default is true, can be omitted + }, + { + title = "Deploy Server Key" + key = "ssh-rsa AAAAB3NzaC1yc2EBBB..." + read_only = false # Write access for deployment + } + ] +} +``` + ## Inputs | Name | Description | Type | Required | Default | @@ -327,6 +352,7 @@ No modules. | [template\_repo\_org](#input\_template\_repo\_org) | Template repository organization | `string` | `null` | no | | [vars](#input\_vars) | GitHub Actions variables |
list(object({
name = string
value = string
}))
| `[]` | no | | [vulnerability\_alerts](#input\_vulnerability\_alerts) | Enable Dependabot alerts | `bool` | `false` | no | +| [deploy\_keys](#input\_deploy\_keys) | List of SSH deploy keys to add to the repository |
list(object({
title = string
key = string
read_only = optional(bool, true)
}))
| `[]` | no | ## Outputs