-
Notifications
You must be signed in to change notification settings - Fork 64
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
Added a parameters for LoadBalancer resource #152
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @coderGo93 - you'll need to add outbound_rules to the docs, as well tests for both properties in addtion to the comments i've left inline
@@ -121,6 +132,16 @@ func loadBalancer() *pluginsdk.Resource { | |||
Set: pluginsdk.HashString, | |||
}, | |||
|
|||
"outbound_rules": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be
"outbound_rules": { | |
"outbound_rule_ids": { |
loadBalancer := network.LoadBalancer{ | ||
Name: pointer.FromString(id.Name), | ||
Location: pointer.FromString(location.Normalize(d.Get("location").(string))), | ||
Tags: tags.Expand(d.Get("tags").(map[string]interface{})), | ||
Sku: &sku, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could we set this inline? theres nor eason to have a variable for it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, will do that, thank you
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks @coderGo93 - couple comments
ForceNew: true, | ||
ValidateFunc: validation.StringInSlice([]string{ | ||
string(network.LoadBalancerSkuNameBasic), | ||
}, true), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should never ignore case unless requires
}, true), | |
}, false), |
@@ -121,6 +131,16 @@ func loadBalancer() *pluginsdk.Resource { | |||
Set: pluginsdk.HashString, | |||
}, | |||
|
|||
"outbound_rules_id": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be rule ids?
"outbound_rules_id": { | |
"outbound_rule_ids": { |
@@ -121,6 +131,16 @@ func loadBalancer() *pluginsdk.Resource { | |||
Set: pluginsdk.HashString, | |||
}, | |||
|
|||
"outbound_rule_ids": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could we ensure these are covered by a test?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems in order to appear the outbound rules, it will need a resource azurestack_public_ip_prefix
but it is not available at the moment, I can remove the parameter outbound_rule_ids
or keep it. What do you think? @katbyte
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can either open a new PR with that resource or add it to this one but that property needs to be be tested to be included here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed the parameter because the resource azurestack_public_ip_prefix
it's not supported at the current profile.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @coderGo93 - LGTM 🔮
sku
andoutbound_rules
for resourceazurestack_lb