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

New Resource - azurerm_mssql_server #6677

Merged
merged 4 commits into from Apr 29, 2020
Merged

New Resource - azurerm_mssql_server #6677

merged 4 commits into from Apr 29, 2020

Conversation

katbyte
Copy link
Collaborator

@katbyte katbyte commented Apr 29, 2020

version of sql server using the v3.0 rollup composite SDK/api

@katbyte katbyte added new-resource service/mssql Microsoft SQL Server labels Apr 29, 2020
@katbyte katbyte added this to the v2.8.0 milestone Apr 29, 2020
@katbyte katbyte requested a review from a team April 29, 2020 00:20
@ghost ghost added size/XXL and removed size/XL labels Apr 29, 2020
Copy link
Member

@mbfrahry mbfrahry left a comment

Choose a reason for hiding this comment

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

LGTM with some minor fixes. I think the doc changes got mismatched and need another look

@@ -42,6 +42,61 @@ func ExtendedAuditingSchema() *schema.Schema {
}
}

func ExpandAzureRmSqlServerBlobAuditingPolicies(input []interface{}) *sql.ExtendedServerBlobAuditingPolicyProperties {
if len(input) == 0 {
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
if len(input) == 0 {
if len(input) == 0 || input[0] == nil {

Just some extra panic protection


func expandAzureRmSqlServerIdentity(d *schema.ResourceData) *sql.ResourceIdentity {
identities := d.Get("identity").([]interface{})
if len(identities) == 0 {
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
if len(identities) == 0 {
if len(identities) == 0 || identities[0] == nil {

@@ -1263,10 +1263,18 @@
<a href="/docs/providers/azurerm/r/sql_server.html">azurerm_sql_server</a>
</li>

<li>
<a href="/docs/providers/azurerm/r/mssql_database.html">azurerm_mssql_database</a>
Copy link
Member

Choose a reason for hiding this comment

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

It looks like this was already specified here. Do we want to remove that one as well?

SQL Servers can be imported using the `resource id`, e.g.

```shell
terraform import azurerm_sql_server.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myresourcegroup/providers/Microsoft.Sql/servers/myserver
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
terraform import azurerm_sql_server.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myresourcegroup/providers/Microsoft.Sql/servers/myserver
terraform import azurerm_mssql_server.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myresourcegroup/providers/Microsoft.Sql/servers/myserver

@@ -1,15 +1,15 @@
---
subcategory: "Database"
layout: "azurerm"
page_title: "Azure Resource Manager: azurerm_sql_server"
Copy link
Member

Choose a reason for hiding this comment

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

I think these changes got misplaced. Should this one stay sql_server?


---

# azurerm_sql_server
Copy link
Member

Choose a reason for hiding this comment

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

Should this be azurerm_mssql_server?

@ghost
Copy link

ghost commented May 1, 2020

This has been released in version 2.8.0 of the provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. As an example:

provider "azurerm" {
    version = "~> 2.8.0"
}
# ... other configuration ...

@ghost
Copy link

ghost commented May 30, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks!

@hashicorp hashicorp locked and limited conversation to collaborators May 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants