Giter Club home page Giter Club logo

Comments (3)

tombuildsstuff avatar tombuildsstuff commented on August 27, 2024

Hey @shanielh

Thanks for opening this issue - apologies for the delayed response here!

Support for this was added in hashicorp/terraform#14608 which shipped in Terraform v0.9.6. As such it's now possible to attach data disks to VM Scale Set using the following Terraform configuration:

  storage_profile_data_disk {
    lun               = 0
    caching           = "ReadWrite"
    create_option     = "Empty"
    disk_size_gb      = 10
    managed_disk_type = "Standard_LRS"
  }

There's more documentation available on the Terraform Website too.

Would it be possible to take a look and see if upgrading to the latest version of Terraform (currently 0.10.2) fixes this issue for you? In the interim I'm going to close this issue since it appears to be fixed, however please feel free to re-open it if there's still an issue here and we'll take a look :)

Thanks!

from terraform-provider-azurerm.

sampcoug avatar sampcoug commented on August 27, 2024

@tombuildsstuff , I have created azurerm_virtual_machine_scale_set and used the configuration below to attach the data disk to the VM Scale set.

 storage_profile_data_disk {
    lun           = 0
    caching       = "ReadWrite"
    create_option = "Empty"
    disk_size_gb  = 100
  }

It shows that the disk has been attached when I run the query below:

az vmss show \
>   --resource-group xxx-resourceGroup \
>   --namexxx-scaleset \
>   --query virtualMachineProfile.storageProfile.dataDisks
[
  {
    "caching": "ReadWrite",
    "createOption": "Empty",
    "diskSizeGb": 100,
    "lun": 0,
    "managedDisk": {
      "storageAccountType": "Standard_LRS"
    },
    "name": null,
    "writeAcceleratorEnabled": null
  }
]

Is the disk in prepared state or they have to be prepared as mentioned in this article - https://docs.microsoft.com/en-us/azure/virtual-machine-scale-sets/tutorial-use-disks-cli#prepare-the-data-disks?
If they need to be prepared, how do we go about preparing them using the terraform?

from terraform-provider-azurerm.

 avatar commented on August 27, 2024

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 👉 [email protected]. Thanks!

from terraform-provider-azurerm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.