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

Add health_check to aws_elb resource #109

Merged
merged 2 commits into from
Jul 30, 2014
Merged

Add health_check to aws_elb resource #109

merged 2 commits into from
Jul 30, 2014

Conversation

vertis
Copy link
Contributor

@vertis vertis commented Jul 30, 2014

I'm not sure I've done this right, but this IS working if you add mitchellh/goamz#71.

There can only be one health_check per ELB, but I can't work out how you can assert that there is only one, and that you don't need an array.

Also, I will probably need to rebase this PR if you merge #103 (add subnets and internal to the ELB resource), since it affects nearly the same lines.

@vertis
Copy link
Contributor Author

vertis commented Jul 30, 2014

Also this can absolutely be switched to Update as well, just starting with the minimal approach


if _, ok := rs.Attributes["health_check.#"]; ok {
v := flatmap.Expand(rs.Attributes, "health_check").([]interface{})
health_check := v[0].(map[string]interface{})
Copy link
Contributor

Choose a reason for hiding this comment

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

Yea, right now with how we handle embedded objects, this is the best we can do. Extra health checks will just be ignored, which is fine.

@pearkes
Copy link
Contributor

pearkes commented Jul 30, 2014

Great! I'm going to merge this in and add an acceptance test case for it, which I'll cc you on. Thanks!

pearkes added a commit that referenced this pull request Jul 30, 2014
@pearkes pearkes merged commit c2f718d into hashicorp:master Jul 30, 2014
@ghost ghost locked and limited conversation to collaborators May 5, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants