{"id":19978364,"url":"https://github.com/geekcell/terraform-aws-iam-role","last_synced_at":"2025-09-08T00:33:41.897Z","repository":{"id":65837628,"uuid":"585621333","full_name":"geekcell/terraform-aws-iam-role","owner":"geekcell","description":"Terraform module to provision an AWS IAM Role.","archived":false,"fork":false,"pushed_at":"2023-10-27T11:11:12.000Z","size":55,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-09-05T16:08:53.710Z","etag":null,"topics":["aws","iam","iam-role","terraform","terraform-module"],"latest_commit_sha":null,"homepage":"https://www.geekcell.io","language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/geekcell.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"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":"2023-01-05T16:32:17.000Z","updated_at":"2023-05-11T13:00:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"f09ffc2d-5c9d-497a-af0b-17edb1dbabae","html_url":"https://github.com/geekcell/terraform-aws-iam-role","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":"geekcell/terraform-aws-module-template","purl":"pkg:github/geekcell/terraform-aws-iam-role","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekcell%2Fterraform-aws-iam-role","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekcell%2Fterraform-aws-iam-role/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekcell%2Fterraform-aws-iam-role/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekcell%2Fterraform-aws-iam-role/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/geekcell","download_url":"https://codeload.github.com/geekcell/terraform-aws-iam-role/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekcell%2Fterraform-aws-iam-role/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274117195,"owners_count":25225101,"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","status":"online","status_checked_at":"2025-09-07T02:00:09.463Z","response_time":67,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["aws","iam","iam-role","terraform","terraform-module"],"created_at":"2024-11-13T03:33:10.328Z","updated_at":"2025-09-08T00:33:41.870Z","avatar_url":"https://github.com/geekcell.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!-- BEGIN_TF_DOCS --\u003e\n[![Geek Cell GmbH](https://raw.githubusercontent.com/geekcell/.github/main/geekcell-github-banner.png)](https://www.geekcell.io/)\n\n### Code Quality\n[![License](https://img.shields.io/github/license/geekcell/terraform-aws-iam-role)](https://github.com/geekcell/terraform-aws-iam-role/blob/master/LICENSE)\n[![GitHub release (latest tag)](https://img.shields.io/github/v/release/geekcell/terraform-aws-iam-role?logo=github\u0026sort=semver)](https://github.com/geekcell/terraform-aws-iam-role/releases)\n[![Release](https://github.com/geekcell/terraform-aws-iam-role/actions/workflows/release.yaml/badge.svg)](https://github.com/geekcell/terraform-aws-iam-role/actions/workflows/release.yaml)\n[![Validate](https://github.com/geekcell/terraform-aws-iam-role/actions/workflows/validate.yaml/badge.svg)](https://github.com/geekcell/terraform-aws-iam-role/actions/workflows/validate.yaml)\n[![Lint](https://github.com/geekcell/terraform-aws-iam-role/actions/workflows/linter.yaml/badge.svg)](https://github.com/geekcell/terraform-aws-iam-role/actions/workflows/linter.yaml)\n[![Test](https://github.com/geekcell/terraform-aws-iam-role/actions/workflows/test.yaml/badge.svg)](https://github.com/geekcell/terraform-aws-iam-role/actions/workflows/test.yaml)\n\n### Security\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/general)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=INFRASTRUCTURE+SECURITY)\n\n#### Cloud\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_aws)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+AWS+V1.2)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_aws_13)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+AWS+V1.3)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_azure)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+AZURE+V1.1)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_azure_13)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+AZURE+V1.3)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_gcp)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+GCP+V1.1)\n\n##### Container\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_kubernetes_16)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+KUBERNETES+V1.6)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_eks_11)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+EKS+V1.1)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_gke_11)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+GKE+V1.1)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/cis_kubernetes)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=CIS+KUBERNETES+V1.5)\n\n#### Data protection\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/soc2)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=SOC2)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/pci)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=PCI-DSS+V3.2)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/pci_dss_v321)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=PCI-DSS+V3.2.1)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/iso)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=ISO27001)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/nist)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=NIST-800-53)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/hipaa)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=HIPAA)\n[![Infrastructure Tests](https://www.bridgecrew.cloud/badges/github/geekcell/terraform-aws-iam-role/fedramp_moderate)](https://www.bridgecrew.cloud/link/badge?vcs=github\u0026fullRepo=geekcell%2Fterraform-aws-iam-role\u0026benchmark=FEDRAMP+%28MODERATE%29)\n\n# Terraform AWS IAM Role\n\nIntroducing the AWS IAM Role Terraform Module, a highly efficient solution for creating and managing your AWS\nIdentity and Access Management (IAM) roles. This module has been expertly crafted to provide you with a simple and\nstreamlined way to create and manage your IAM roles within AWS.\n\nOur team of experts has years of experience working with AWS IAM and has a deep understanding of the best practices\nand configurations. By using this Terraform module, you can be sure that your IAM roles are created and managed in\na secure, efficient, and scalable manner.\n\nThis module offers a preconfigured solution for creating IAM roles, saving you time and effort in the process.\nWhether you're looking to grant access to specific AWS services or to limit the actions that can be performed on\nyour resources, this module has you covered.\n\nSo, if you're looking for a convenient and reliable solution for creating and managing your IAM roles within AWS,\nlook no further than the AWS IAM Role Terraform Module. Give it a try and see the difference it can make in your\nAWS setup!\n\n## Inputs\n\n| Name | Description | Type | Default | Required |\n|------|-------------|------|---------|:--------:|\n| \u003ca name=\"input_assume_role_json\"\u003e\u003c/a\u003e [assume\\_role\\_json](#input\\_assume\\_role\\_json) | A rendered JSON string of the `assume_roles` variable. | `string` | `null` | no |\n| \u003ca name=\"input_assume_roles\"\u003e\u003c/a\u003e [assume\\_roles](#input\\_assume\\_roles) | A map of principals which can assume the role. The default action is: `[\"sts:AssumeRole\"]` | \u003cpre\u003emap(object({\u003cbr\u003e    actions     = optional(list(string))\u003cbr\u003e    identifiers = list(string)\u003cbr\u003e\u003cbr\u003e    conditions = optional(list(object({\u003cbr\u003e      test     = string\u003cbr\u003e      variable = string\u003cbr\u003e      values   = list(string)\u003cbr\u003e    })))\u003cbr\u003e  }))\u003c/pre\u003e | `{}` | no |\n| \u003ca name=\"input_description\"\u003e\u003c/a\u003e [description](#input\\_description) | Description of the Role. | `string` | `null` | no |\n| \u003ca name=\"input_enable_iam_instance_profile\"\u003e\u003c/a\u003e [enable\\_iam\\_instance\\_profile](#input\\_enable\\_iam\\_instance\\_profile) | If enabled, will create an IAM instance profile for this role. | `bool` | `false` | no |\n| \u003ca name=\"input_force_detach_policies\"\u003e\u003c/a\u003e [force\\_detach\\_policies](#input\\_force\\_detach\\_policies) | Whether to force detaching any policies the role has before destroying it. | `bool` | `false` | no |\n| \u003ca name=\"input_max_session_duration\"\u003e\u003c/a\u003e [max\\_session\\_duration](#input\\_max\\_session\\_duration) | Maximum session duration (in seconds) that you want to set for the specified role. | `number` | `3600` | no |\n| \u003ca name=\"input_name\"\u003e\u003c/a\u003e [name](#input\\_name) | Name or prefix of the Role. | `string` | n/a | yes |\n| \u003ca name=\"input_path\"\u003e\u003c/a\u003e [path](#input\\_path) | Path to the role. | `string` | `\"/\"` | no |\n| \u003ca name=\"input_permissions_boundary\"\u003e\u003c/a\u003e [permissions\\_boundary](#input\\_permissions\\_boundary) | ARN of the policy that is used to set the permissions boundary for the role. | `string` | `null` | no |\n| \u003ca name=\"input_policy_arns\"\u003e\u003c/a\u003e [policy\\_arns](#input\\_policy\\_arns) | A list of policy ARNs to attach to the role. | `list(string)` | `[]` | no |\n| \u003ca name=\"input_tags\"\u003e\u003c/a\u003e [tags](#input\\_tags) | Tags to add to the Role. | `map(any)` | `{}` | no |\n| \u003ca name=\"input_use_name_prefix\"\u003e\u003c/a\u003e [use\\_name\\_prefix](#input\\_use\\_name\\_prefix) | Use the `name` attribute as prefix for the role name. | `bool` | `true` | no |\n\n## Outputs\n\n| Name | Description |\n|------|-------------|\n| \u003ca name=\"output_arn\"\u003e\u003c/a\u003e [arn](#output\\_arn) | IAM role arn |\n| \u003ca name=\"output_instance_profile_arn\"\u003e\u003c/a\u003e [instance\\_profile\\_arn](#output\\_instance\\_profile\\_arn) | IAM instance profile arn |\n| \u003ca name=\"output_name\"\u003e\u003c/a\u003e [name](#output\\_name) | IAM role name |\n\n## Providers\n\n| Name | Version |\n|------|---------|\n| \u003ca name=\"provider_aws\"\u003e\u003c/a\u003e [aws](#provider\\_aws) | \u003e= 4.36 |\n\n## Resources\n\n- resource.aws_iam_instance_profile.main (main.tf#77)\n- resource.aws_iam_role.main (main.tf#55)\n- resource.aws_iam_role_policy_attachment.main (main.tf#70)\n- data source.aws_iam_policy_document.assume (main.tf#20)\n- data source.aws_iam_policy_document.assume_combined (main.tf#47)\n\n# Examples\n### Minimal\n```hcl\nmodule \"basic-example\" {\n  source = \"../../\"\n\n  name = var.name\n\n  assume_roles = {\n    AWS : {\n      identifiers : [var.account]\n    }\n  }\n\n  policy_arns = [\"arn:aws:iam::aws:policy/ReadOnlyAccess\"]\n}\n```\n\u003c!-- END_TF_DOCS --\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeekcell%2Fterraform-aws-iam-role","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgeekcell%2Fterraform-aws-iam-role","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeekcell%2Fterraform-aws-iam-role/lists"}