Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tokarev-artem/terraform-aws-ram
Terraform module to share AWS resources using AWS RAM service
https://github.com/tokarev-artem/terraform-aws-ram
amazon aws terraform terraform-module
Last synced: 3 months ago
JSON representation
Terraform module to share AWS resources using AWS RAM service
- Host: GitHub
- URL: https://github.com/tokarev-artem/terraform-aws-ram
- Owner: tokarev-artem
- Created: 2024-05-10T22:58:35.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-06-13T20:26:30.000Z (7 months ago)
- Last Synced: 2024-09-27T19:01:19.849Z (4 months ago)
- Topics: amazon, aws, terraform, terraform-module
- Language: HCL
- Homepage:
- Size: 10.7 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
# AWS RAM module
This module allows you to share [supported](https://docs.aws.amazon.com/ram/latest/userguide/shareable.html) AWS resources to another accounts or AWS organization
# Example usage:
```hcl
module "aws-ram" {
source = "tokarev-artem/ram/aws"
version = "~> 1.0"
name = "Share Subnets to develop account"
resource_arns = ["arn:aws:ec2:eu-central-1:123456789101:subnet/subnet-1234567abcd", "arn:aws:ec2:eu-central-1:123456789101:subnet/subnet-abcdef1234"]
principals = ["arn:aws:organizations::101987654321:organization/o-abcdef1234", "55555555555"]
tags = {
OwnedBy = "network"
}
}
```
For organization unit - need to use ARN, but not o-XXXXXXXXXX id, arn can be taken by simply running: `$ aws organizations describe-organization`Documentation: https://docs.aws.amazon.com/cli/latest/reference/organizations/describe-organization.html
If you wish to share with the principal, accepting the sharing is mandatory. Please see examples.
## Providers
| Name | Version |
|------|---------|
| [aws](#provider\_aws) | >= 4.66 |## Outputs
| Name | Description |
|------|-------------|
| [principal\_association\_arns](#output\_principal\_association\_arns) | The ARNs of the principal associations |
| [resource\_association\_arns](#output\_resource\_association\_arns) | The ARNs of the resource associations |
| [resource\_share\_arn](#output\_resource\_share\_arn) | The ARN of the created resource share |## Inputs
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| [name](#input\_name) | The name of the resource share. | `string` | n/a | yes |
| [principals](#input\_principals) | The principal to associate with the resource share. Possible values are an AWS account ID, an AWS Organizations Organization ARN, or an AWS Organizations Organization Unit ARN | `list(string)` | n/a | yes |
| [resource\_arns](#input\_resource\_arns) | The Amazon Resource Name (ARN) of the resource share. | `list(string)` | n/a | yes |
| [allow\_external\_principals](#input\_allow\_external\_principals) | Indicates whether principals outside your organization can be associated with a resource share. | `bool` | `true` | no |
| [permission\_arns](#input\_permission\_arns) | Specifies the Amazon Resource Names (ARNs) of the RAM permission to associate with the resource share. If you do not specify an ARN for the permission, RAM automatically attaches the default version of the permission for each resource type. You can associate only one permission with each resource type included in the resource share. | `list(string)` | `[]` | no |
| [tags](#input\_tags) | Tags map for aws\_ram\_resource\_share resource | `map(string)` | `{}` | no |