Skip to content

Commit

Permalink
chore: update docs and var description (#46)
Browse files Browse the repository at this point in the history
* chore: update docs and var description

* fix: type fix for force_detach_policies variable
  • Loading branch information
saidsef authored Dec 23, 2024
1 parent ff9ef77 commit 8897459
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 33 deletions.
34 changes: 17 additions & 17 deletions TERRAFORM.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
| Name | Version |
|------|---------|
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | ~> 1 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 4 |
| <a name="requirement_tls"></a> [tls](#requirement\_tls) | >= 4 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 4, < 6 |
| <a name="requirement_tls"></a> [tls](#requirement\_tls) | >= 4, < 5 |

## Providers

| Name | Version |
|------|---------|
| <a name="provider_aws"></a> [aws](#provider\_aws) | 4.47.0 |
| <a name="provider_tls"></a> [tls](#provider\_tls) | 4.0.4 |
| <a name="provider_aws"></a> [aws](#provider\_aws) | 5.51.1 |
| <a name="provider_tls"></a> [tls](#provider\_tls) | 4.0.5 |

## Modules

Expand All @@ -35,20 +35,20 @@ No modules.

| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| <a name="input_attach_admin_policy"></a> [attach\_admin\_policy](#input\_attach\_admin\_policy) | Enable attachment of the AdministratorAccess policy | `bool` | `false` | no |
| <a name="input_attach_read_only_policy"></a> [attach\_read\_only\_policy](#input\_attach\_read\_only\_policy) | Enable attachment of the ReadOnly policy | `bool` | `true` | no |
| <a name="input_create_oidc_provider"></a> [create\_oidc\_provider](#input\_create\_oidc\_provider) | Enable creation of the GitHub OIDC provider | `bool` | `true` | no |
| <a name="input_enabled"></a> [enabled](#input\_enabled) | Enable creation of resources | `bool` | `true` | no |
| <a name="input_force_detach_policies"></a> [force\_detach\_policies](#input\_force\_detach\_policies) | Force detachment of policies attached to the IAM role | `string` | `false` | no |
| <a name="input_attach_admin_policy"></a> [attach\_admin\_policy](#input\_attach\_admin\_policy) | Attach AdministratorAccess policy | `bool` | `false` | no |
| <a name="input_attach_read_only_policy"></a> [attach\_read\_only\_policy](#input\_attach\_read\_only\_policy) | Attach ReadOnly policy | `bool` | `true` | no |
| <a name="input_create_oidc_provider"></a> [create\_oidc\_provider](#input\_create\_oidc\_provider) | Create GitHub OIDC provider | `bool` | `true` | no |
| <a name="input_enabled"></a> [enabled](#input\_enabled) | Enable resource creation | `bool` | `true` | no |
| <a name="input_force_detach_policies"></a> [force\_detach\_policies](#input\_force\_detach\_policies) | Force detach IAM policies | `bool` | `false` | no |
| <a name="input_github_organisation"></a> [github\_organisation](#input\_github\_organisation) | GitHub organisation name | `string` | n/a | yes |
| <a name="input_github_repositories"></a> [github\_repositories](#input\_github\_repositories) | List of GitHub repository name(s) and branche names or patterns | <pre>list(object({<br> name = string<br> branches = list(string)<br> }))</pre> | <pre>[<br> {<br> "branches": null,<br> "name": null<br> }<br>]</pre> | no |
| <a name="input_iam_role_name"></a> [iam\_role\_name](#input\_iam\_role\_name) | Name of the IAM role | `string` | `"github-actions"` | no |
| <a name="input_iam_role_path"></a> [iam\_role\_path](#input\_iam\_role\_path) | Path to the IAM role | `string` | `"/"` | no |
| <a name="input_iam_role_permissions_boundary"></a> [iam\_role\_permissions\_boundary](#input\_iam\_role\_permissions\_boundary) | ARN of the permissions boundary to be used by the IAM role | `string` | `""` | no |
| <a name="input_iam_role_policy_arns"></a> [iam\_role\_policy\_arns](#input\_iam\_role\_policy\_arns) | List of IAM policy ARNs to attach to the IAM role | `list(string)` | `[]` | no |
| <a name="input_max_session_duration"></a> [max\_session\_duration](#input\_max\_session\_duration) | Maximum session duration in seconds | `number` | `3600` | no |
| <a name="input_tags"></a> [tags](#input\_tags) | Map of tags to be applied to all resources | `map(string)` | `{}` | no |
| <a name="input_url"></a> [url](#input\_url) | URL of identity provider | `string` | `"token.actions.githubusercontent.com"` | no |
| <a name="input_github_repositories"></a> [github\_repositories](#input\_github\_repositories) | GitHub repository names and branches | <pre>list(object({<br/> name = string<br/> branches = list(string)<br/> }))</pre> | <pre>[<br/> {<br/> "branches": null,<br/> "name": null<br/> }<br/>]</pre> | no |
| <a name="input_iam_role_name"></a> [iam\_role\_name](#input\_iam\_role\_name) | IAM role name | `string` | `"github-actions"` | no |
| <a name="input_iam_role_path"></a> [iam\_role\_path](#input\_iam\_role\_path) | IAM role path | `string` | `"/"` | no |
| <a name="input_iam_role_permissions_boundary"></a> [iam\_role\_permissions\_boundary](#input\_iam\_role\_permissions\_boundary) | IAM role permissions boundary ARN | `string` | `""` | no |
| <a name="input_iam_role_policy_arns"></a> [iam\_role\_policy\_arns](#input\_iam\_role\_policy\_arns) | IAM policy ARNs to attach | `list(string)` | `[]` | no |
| <a name="input_max_session_duration"></a> [max\_session\_duration](#input\_max\_session\_duration) | Session duration in seconds | `number` | `3600` | no |
| <a name="input_tags"></a> [tags](#input\_tags) | Tags to apply to resources | `map(string)` | `{}` | no |
| <a name="input_url"></a> [url](#input\_url) | Identity provider URL | `string` | `"token.actions.githubusercontent.com"` | no |

## Outputs

Expand Down
2 changes: 1 addition & 1 deletion examples/complete/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ variable "enabled" {
variable "force_detach_policies" {
default = false
description = "Force detachment of policies attached to the IAM role"
type = string
type = bool
}

variable "github_organisation" {
Expand Down
30 changes: 15 additions & 15 deletions variables.tf
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
variable "attach_admin_policy" {
default = false
description = "Enable attachment of the AdministratorAccess policy"
description = "Attach AdministratorAccess policy"
type = bool
}

variable "attach_read_only_policy" {
default = true
description = "Enable attachment of the ReadOnly policy"
description = "Attach ReadOnly policy"
type = bool
}

variable "create_oidc_provider" {
default = true
description = "Enable creation of the GitHub OIDC provider"
description = "Create GitHub OIDC provider"
type = bool
}

variable "enabled" {
default = true
description = "Enable creation of resources"
description = "Enable resource creation"
type = bool
}

variable "force_detach_policies" {
default = false
description = "Force detachment of policies attached to the IAM role"
type = string
description = "Force detach IAM policies"
type = bool
}

variable "github_organisation" {
Expand All @@ -42,58 +42,58 @@ variable "github_repositories" {
branches = null
name = null
}]
description = "List of GitHub repository name(s) and branche names or patterns"
description = "GitHub repository names and branches"
}

variable "iam_role_name" {
default = "github-actions"
description = "Name of the IAM role"
description = "IAM role name"
type = string
}

variable "iam_role_path" {
default = "/"
description = "Path to the IAM role"
description = "IAM role path"
type = string
sensitive = false
}

variable "iam_role_permissions_boundary" {
default = ""
description = "ARN of the permissions boundary to be used by the IAM role"
description = "IAM role permissions boundary ARN"
type = string
sensitive = false
}

variable "iam_role_policy_arns" {
default = []
description = "List of IAM policy ARNs to attach to the IAM role"
description = "IAM policy ARNs to attach"
type = list(string)
sensitive = false
}

variable "max_session_duration" {
default = 3600
description = "Maximum session duration in seconds"
description = "Session duration in seconds"
type = number
sensitive = false

validation {
condition = var.max_session_duration >= 3600 && var.max_session_duration <= 43200
error_message = "Session duration must be between 3600 and 43200 seconds."
error_message = "Must be between 3600 and 43200 seconds."
}
}

variable "url" {
type = string
description = "URL of identity provider"
description = "Identity provider URL"
default = "token.actions.githubusercontent.com"
sensitive = false
}

variable "tags" {
default = {}
description = "Map of tags to be applied to all resources"
description = "Tags to apply to resources"
type = map(string)
sensitive = false
}

0 comments on commit 8897459

Please sign in to comment.