Skip to content

Commit 484b1b3

Browse files
committed
comply with pre-commit rules
1 parent 06ec4c0 commit 484b1b3

File tree

1 file changed

+34
-4
lines changed

1 file changed

+34
-4
lines changed

README.md

Lines changed: 34 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,35 +81,65 @@ See `examples` directory for working examples to reference
8181
## Available features
8282

8383
<!-- BEGINNING OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
84+
# AWS Gitlab OIDC Provider Terraform Module
85+
86+
## Purpose
87+
This module allows you to create a Gitlab OIDC provider for your AWS account, that will allow Gitlab pipelines to securely authenticate against the AWS API using an IAM role
88+
8489
## Requirements
8590

8691
| Name | Version |
8792
|------|---------|
8893
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1 |
94+
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 5.40 |
95+
| <a name="requirement_tls"></a> [tls](#requirement\_tls) | >= 3.0 |
8996

9097
## Providers
9198

92-
No providers.
99+
| Name | Version |
100+
|------|---------|
101+
| <a name="provider_aws"></a> [aws](#provider\_aws) | >= 5.40 |
102+
| <a name="provider_tls"></a> [tls](#provider\_tls) | >= 3.0 |
93103

94104
## Modules
95105

96106
No modules.
97107

98108
## Resources
99109

100-
No resources.
110+
| Name | Type |
111+
|------|------|
112+
| [aws_iam_openid_connect_provider.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_openid_connect_provider) | resource |
113+
| [aws_iam_role.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role) | resource |
114+
| [aws_iam_role_policy_attachment.attach](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/iam_role_policy_attachment) | resource |
115+
| [aws_iam_policy_document.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) | data source |
116+
| [tls_certificate.gitlab](https://registry.terraform.io/providers/hashicorp/tls/latest/docs/data-sources/certificate) | data source |
101117

102118
## Inputs
103119

104120
| Name | Description | Type | Default | Required |
105121
|------|-------------|------|---------|:--------:|
106-
| <a name="input_variable"></a> [variable](#input\_variable) | defaul,description,type | `string` | `"variable"` | no |
122+
| <a name="input_aud_value"></a> [aud\_value](#input\_aud\_value) | (Required) A list of client IDs (also known as audiences). When a mobile or web app registers with an OpenID Connect provider, they establish a value that identifies the application. (This is the value that's sent as the client\_id parameter on OAuth requests.) | `list(string)` | <pre>[<br> "https://gitlab.com"<br>]</pre> | no |
123+
| <a name="input_create_oidc_provider"></a> [create\_oidc\_provider](#input\_create\_oidc\_provider) | Whether or not to create the associated oidc provider. If false, variable 'oidc\_provider\_arn' is required | `bool` | `true` | no |
124+
| <a name="input_create_oidc_role"></a> [create\_oidc\_role](#input\_create\_oidc\_role) | Whether or not to create the OIDC attached role | `bool` | `true` | no |
125+
| <a name="input_gitlab_tls_url"></a> [gitlab\_tls\_url](#input\_gitlab\_tls\_url) | the Hashicorp TLS provider has started following redirects starting v4. so we use tls:// | `string` | `"tls://gitlab.com:443"` | no |
126+
| <a name="input_match_field"></a> [match\_field](#input\_match\_field) | the token field the OIDC provider filter on | `string` | `"sub"` | no |
127+
| <a name="input_max_session_duration"></a> [max\_session\_duration](#input\_max\_session\_duration) | Maximum session duration in seconds. | `number` | `3600` | no |
128+
| <a name="input_oidc_role_attach_policies"></a> [oidc\_role\_attach\_policies](#input\_oidc\_role\_attach\_policies) | Attach policies to OIDC role. | `list(string)` | `[]` | no |
129+
| <a name="input_projects"></a> [projects](#input\_projects) | List of GitLab namesapce/project names authorized to assume the role. | `list(string)` | `[]` | no |
130+
| <a name="input_role_description"></a> [role\_description](#input\_role\_description) | (Optional) Description of the role. | `string` | `"Role assumed by the Gitlab OIDC provider."` | no |
131+
| <a name="input_role_name"></a> [role\_name](#input\_role\_name) | (Optional, Forces new resource) Friendly name of the role. | `string` | `"gitlab-oidc-provider-aws"` | no |
132+
| <a name="input_tags"></a> [tags](#input\_tags) | A mapping of tags to assign to all resources | `map(string)` | `{}` | no |
133+
| <a name="input_url"></a> [url](#input\_url) | GitLab OpenID TLS certificate URL. The address of your GitLab instance, such as https://gitlab.com or http://gitlab.example.com. | `string` | `"https://gitlab.com"` | no |
107134

108135
## Outputs
109136

110137
| Name | Description |
111138
|------|-------------|
112-
| <a name="output_used"></a> [used](#output\_used) | used value |
139+
| <a name="output_oidc_provider_arn"></a> [oidc\_provider\_arn](#output\_oidc\_provider\_arn) | OIDC provider ARN |
140+
| <a name="output_oidc_role"></a> [oidc\_role](#output\_oidc\_role) | CICD GitHub role. |
141+
| <a name="output_policy_document"></a> [policy\_document](#output\_policy\_document) | joined IAM policy documents |
142+
| <a name="output_thumbprint"></a> [thumbprint](#output\_thumbprint) | TLS endpoint certificate SHA1 Fingerprint |
113143
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
114144

115145

0 commit comments

Comments
 (0)