-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
azurerm_public_ip_prefix: adding sku_tier
property
#27882
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 for this @CorrenSoft! This looks good, I just have one question and a suggestion. Once those are resolved this should be good to merge.
ValidateFunc: validation.StringInSlice([]string{ | ||
string(publicipprefixes.PublicIPPrefixSkuTierGlobal), | ||
string(publicipprefixes.PublicIPPrefixSkuTierRegional), | ||
}, false), |
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.
This can be replaced with
ValidateFunc: validation.StringInSlice([]string{ | |
string(publicipprefixes.PublicIPPrefixSkuTierGlobal), | |
string(publicipprefixes.PublicIPPrefixSkuTierRegional), | |
}, false), | |
ValidateFunc: validation.StringInSlice(PossibleValuesForPublicIPPrefixSkuTier(), false), |
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.
Lovely, thank you.
"sku_tier": { | ||
Type: pluginsdk.TypeString, | ||
Optional: true, | ||
Default: string(publicipprefixes.PublicIPPrefixSkuTierRegional), |
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.
Just confirming here, but Is this the default that existing resources created by Terraform would have?
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.
Yes, any resource created has that value.
"sku": {
"name": "Standard",
"tier": "Regional"
}
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.
Good stuff, thanks @CorrenSoft LGTM 🧊
I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions. |
Community Note
Description
sku_tier
to the resource and the data source.TestAccDataSourcePublicIPPrefix_basic
to validate the output value.TestAccPublicIpPrefix_globalTier
andTestAccPublicIpPrefix_regionalTier
to test both possible values.PR Checklist
Changes to existing Resource / Data Source
Testing
Note: Missing
TestAccPublicIpPrefix_prefixLength24
because is not accepted in my working subscription.Change Log
Below please provide what should go into the changelog (if anything) conforming to the Changelog Format documented here.
azurerm_public_ip_prefix
- support for thesku_tier
property [Support for configuring SKU tier when creating a Public IP Prefix #27877]This is a (please select all that apply):
Related Issue(s)
Fixes #27877
Note
If this PR changes meaningfully during the course of review please update the title and description as required.