This repository has been archived by the owner on Mar 11, 2021. It is now read-only.
/
getDisk.go
60 lines (55 loc) · 3.12 KB
/
getDisk.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
// *** WARNING: this file was generated by the Pulumi SDK Generator. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package v20180601
import (
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func LookupDisk(ctx *pulumi.Context, args *LookupDiskArgs, opts ...pulumi.InvokeOption) (*LookupDiskResult, error) {
var rv LookupDiskResult
err := ctx.Invoke("azure-nextgen:compute/v20180601:getDisk", args, &rv, opts...)
if err != nil {
return nil, err
}
return &rv, nil
}
type LookupDiskArgs struct {
// The name of the managed disk that is being created. The name can't be changed after the disk is created. Supported characters for the name are a-z, A-Z, 0-9 and _. The maximum name length is 80 characters.
DiskName string `pulumi:"diskName"`
// The name of the resource group.
ResourceGroupName string `pulumi:"resourceGroupName"`
}
// Disk resource.
type LookupDiskResult struct {
// Disk source information. CreationData information cannot be changed after the disk has been created.
CreationData CreationDataResponse `pulumi:"creationData"`
// The number of IOPS allowed for this disk; only settable for UltraSSD disks. One operation can transfer between 4k and 256k bytes. For a description of the range of values you can set, see [Ultra SSD Managed Disk Offerings](https://docs.microsoft.com/azure/virtual-machines/windows/disks-ultra-ssd#ultra-ssd-managed-disk-offerings).
DiskIOPSReadWrite *float64 `pulumi:"diskIOPSReadWrite"`
// The bandwidth allowed for this disk; only settable for UltraSSD disks. MBps means millions of bytes per second - MB here uses the ISO notation, of powers of 10. For a description of the range of values you can set, see [Ultra SSD Managed Disk Offerings](https://docs.microsoft.com/azure/virtual-machines/windows/disks-ultra-ssd#ultra-ssd-managed-disk-offerings).
DiskMBpsReadWrite *int `pulumi:"diskMBpsReadWrite"`
// If creationData.createOption is Empty, this field is mandatory and it indicates the size of the VHD to create. If this field is present for updates or creation with other options, it indicates a resize. Resizes are only allowed if the disk is not attached to a running VM, and can only increase the disk's size.
DiskSizeGB *int `pulumi:"diskSizeGB"`
// Encryption settings for disk or snapshot
EncryptionSettings *EncryptionSettingsResponse `pulumi:"encryptionSettings"`
// Resource Id
Id string `pulumi:"id"`
// Resource location
Location string `pulumi:"location"`
// A relative URI containing the ID of the VM that has the disk attached.
ManagedBy string `pulumi:"managedBy"`
// Resource name
Name string `pulumi:"name"`
// The Operating System type.
OsType *string `pulumi:"osType"`
// The disk provisioning state.
ProvisioningState string `pulumi:"provisioningState"`
// The disks sku name. Can be Standard_LRS, Premium_LRS, StandardSSD_LRS, or UltraSSD_LRS.
Sku *DiskSkuResponse `pulumi:"sku"`
// Resource tags
Tags map[string]string `pulumi:"tags"`
// The time when the disk was created.
TimeCreated string `pulumi:"timeCreated"`
// Resource type
Type string `pulumi:"type"`
// The Logical zone list for Disk.
Zones []string `pulumi:"zones"`
}