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

Data source 'azurerm_mariadb_server' returns no information #6483

Closed
rmaziarka opened this issue Apr 15, 2020 · 3 comments · Fixed by #6496
Closed

Data source 'azurerm_mariadb_server' returns no information #6483

rmaziarka opened this issue Apr 15, 2020 · 3 comments · Fixed by #6496
Assignees
Milestone

Comments

@rmaziarka
Copy link

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform (and AzureRM Provider) Version

  • Terraform: v0.12.24
  • AzureRM: v2.0.0 / v.2.2.0 / v2.5.0

Affected Resource(s)

  • data source azurerm_mariadb_server

Terraform Configuration Files

resource "azurerm_mariadb_server" "server" {
  name                = "servername"
  location            = "WestEurope"
  resource_group_name = "resourcegroupname"
  sku_name            = "B_Gen5_1"

  storage_profile {
    storage_mb            = 51200
    backup_retention_days = 7
    geo_redundant_backup  = "Disabled"
  }

  administrator_login          = "admin"
  administrator_login_password = "password"
  version                      = "10.2"
  ssl_enforcement              = "Enabled"
}

data "azurerm_mariadb_server" "datasource" {
  name                = "servername"
  resource_group_name = "resourcegroupname"
}

output "mariadb_server_id" {
  value = data.azurerm_mariadb_server.datasource.id
}

Expected Behavior

In output I should get:
mariadb_server_id = ........

Actual Behavior

I get no information in output.

Steps to Reproduce

  • terraform apply -auto-approve

Additional information

I reproduced this behavior in 2 different subscriptions, and with different configurations like a resource in the same state as data, data separated from the resource, etc.

In terraform state file I have empty configuration for :

{
    "mode": "data",
    "type": "azurerm_mariadb_server",
    "name": "datasource",
    "provider": "provider.azurerm",
    "instances": [
    {
        "schema_version": 0,
        "attributes": {
        "administrator_login": null,
        "administrator_login_password": null,
        "fqdn": null,
        "id": null,
        "location": null,
        "name": null,
        "resource_group_name": null,
        "sku_name": null,
        "ssl_enforcement": null,
        "storage_profile": null,
        "tags": null,
        "timeouts": null,
        "version": null
        }
    }
    ]
}
@ghost
Copy link

ghost commented Apr 16, 2020

This has been released in version 2.6.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.6.0"
}
# ... other configuration ...

@rmaziarka
Copy link
Author

That was fast, thank you very much!

@ghost
Copy link

ghost commented May 17, 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!

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

Successfully merging a pull request may close this issue.

2 participants