provider/azurerm: removing azurerm_virtual_machine data_disk disk_size_in_gb
This commit is contained in:
parent
f7aea2f447
commit
63aa6a1fcd
|
@ -197,9 +197,9 @@ func resourceArmVirtualMachine() *schema.Resource {
|
|||
},
|
||||
|
||||
"disk_size_gb": {
|
||||
Type: schema.TypeInt,
|
||||
Optional: true,
|
||||
ValidateFunc: validateDiskSizeGB,
|
||||
Type: schema.TypeInt,
|
||||
Optional: true,
|
||||
Computed: true,
|
||||
},
|
||||
|
||||
"lun": {
|
||||
|
@ -1172,7 +1172,6 @@ func expandAzureRmVirtualMachineDataDisk(d *schema.ResourceData) ([]compute.Data
|
|||
vhd := config["vhd_uri"].(string)
|
||||
createOption := config["create_option"].(string)
|
||||
lun := int32(config["lun"].(int))
|
||||
disk_size := int32(config["disk_size_gb"].(int))
|
||||
|
||||
data_disk := compute.DataDisk{
|
||||
Name: &name,
|
||||
|
@ -1180,10 +1179,14 @@ func expandAzureRmVirtualMachineDataDisk(d *schema.ResourceData) ([]compute.Data
|
|||
URI: &vhd,
|
||||
},
|
||||
Lun: &lun,
|
||||
DiskSizeGB: &disk_size,
|
||||
CreateOption: compute.DiskCreateOptionTypes(createOption),
|
||||
}
|
||||
|
||||
if v := config["disk_size_gb"]; v != nil {
|
||||
diskSize := int32(config["disk_size_gb"].(int))
|
||||
data_disk.DiskSizeGB = &diskSize
|
||||
}
|
||||
|
||||
data_disks = append(data_disks, data_disk)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue