Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(output): Rename "role_arn" output to "role_id" #40

Merged
merged 1 commit into from
Apr 5, 2019
Merged

fix(output): Rename "role_arn" output to "role_id" #40

merged 1 commit into from
Apr 5, 2019

Conversation

k911
Copy link
Contributor

@k911 k911 commented Apr 5, 2019

Output role_arn was wrongly named, because it exposes "aws_iam_role.role.id" attribute
instead of "aws_iam_role.role.arn".

I've added both role_arn and role_id, because in my case I've needed
role_arn.

Note: This change is backwards incompatible, and will require changes
when making upgrade of modules using this module.

Example:
https://github.com/cloudposse/terraform-aws-ecs-codepipeline/blob/master/main.tf#L198

resource "aws_iam_role_policy_attachment" "codebuild_s3" {
  count      = "${local.enabled ? 1 : 0}"
-  role       = "${module.build.role_arn}"
+  role       = "${module.build.role_id}"
  policy_arn = "${aws_iam_policy.s3.arn}"
}

Copy link
Member

@aknysh aknysh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks @k911

Looks good, but please rebuild README by executing these commands:

make init
make readme/deps
make readme

It will add the new variables and outputs to README.md automatically.

In general, any changes to README should be made in README.yaml (not in this case), and after that executing the commands above will rebuild README.yaml into README.md and add all new variables and outputs to README.md

thanks

Output `role_arn` was wrongly named, because it exposes "aws_iam_role.role.id" attribute
instead of "aws_iam_role.role.arn".

I've added both `role_arn` and `role_id`, because in my case I've needed
`role_arn`.

Note: This change is backwards incompatible, and will require changes
when making upgrade of modules using this module.
@k911
Copy link
Contributor Author

k911 commented Apr 5, 2019

@aknysh Nice, I've must have missed this, thanks. I've updated PR according to your instructions.

Copy link
Member

@aknysh aknysh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks @k911

@aknysh aknysh merged commit 9e719e7 into cloudposse:master Apr 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants