Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.azurenative.compute.DiskArgs Maven / Gradle / Ivy
Go to download
A native Pulumi package for creating and managing Azure resources.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.azurenative.compute;
import com.pulumi.azurenative.compute.enums.DataAccessAuthMode;
import com.pulumi.azurenative.compute.enums.HyperVGeneration;
import com.pulumi.azurenative.compute.enums.NetworkAccessPolicy;
import com.pulumi.azurenative.compute.enums.OperatingSystemTypes;
import com.pulumi.azurenative.compute.enums.PublicNetworkAccess;
import com.pulumi.azurenative.compute.inputs.CreationDataArgs;
import com.pulumi.azurenative.compute.inputs.DiskSecurityProfileArgs;
import com.pulumi.azurenative.compute.inputs.DiskSkuArgs;
import com.pulumi.azurenative.compute.inputs.EncryptionArgs;
import com.pulumi.azurenative.compute.inputs.EncryptionSettingsCollectionArgs;
import com.pulumi.azurenative.compute.inputs.ExtendedLocationArgs;
import com.pulumi.azurenative.compute.inputs.PurchasePlanArgs;
import com.pulumi.azurenative.compute.inputs.SupportedCapabilitiesArgs;
import com.pulumi.core.Either;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Boolean;
import java.lang.Double;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
public final class DiskArgs extends com.pulumi.resources.ResourceArgs {
public static final DiskArgs Empty = new DiskArgs();
/**
* Set to true to enable bursting beyond the provisioned performance target of the disk. Bursting is disabled by default. Does not apply to Ultra disks.
*
*/
@Import(name="burstingEnabled")
private @Nullable Output burstingEnabled;
/**
* @return Set to true to enable bursting beyond the provisioned performance target of the disk. Bursting is disabled by default. Does not apply to Ultra disks.
*
*/
public Optional> burstingEnabled() {
return Optional.ofNullable(this.burstingEnabled);
}
/**
* Percentage complete for the background copy when a resource is created via the CopyStart operation.
*
*/
@Import(name="completionPercent")
private @Nullable Output completionPercent;
/**
* @return Percentage complete for the background copy when a resource is created via the CopyStart operation.
*
*/
public Optional> completionPercent() {
return Optional.ofNullable(this.completionPercent);
}
/**
* Disk source information. CreationData information cannot be changed after the disk has been created.
*
*/
@Import(name="creationData", required=true)
private Output creationData;
/**
* @return Disk source information. CreationData information cannot be changed after the disk has been created.
*
*/
public Output creationData() {
return this.creationData;
}
/**
* Additional authentication requirements when exporting or uploading to a disk or snapshot.
*
*/
@Import(name="dataAccessAuthMode")
private @Nullable Output> dataAccessAuthMode;
/**
* @return Additional authentication requirements when exporting or uploading to a disk or snapshot.
*
*/
public Optional>> dataAccessAuthMode() {
return Optional.ofNullable(this.dataAccessAuthMode);
}
/**
* ARM id of the DiskAccess resource for using private endpoints on disks.
*
*/
@Import(name="diskAccessId")
private @Nullable Output diskAccessId;
/**
* @return ARM id of the DiskAccess resource for using private endpoints on disks.
*
*/
public Optional> diskAccessId() {
return Optional.ofNullable(this.diskAccessId);
}
/**
* The total number of IOPS that will be allowed across all VMs mounting the shared disk as ReadOnly. One operation can transfer between 4k and 256k bytes.
*
*/
@Import(name="diskIOPSReadOnly")
private @Nullable Output diskIOPSReadOnly;
/**
* @return The total number of IOPS that will be allowed across all VMs mounting the shared disk as ReadOnly. One operation can transfer between 4k and 256k bytes.
*
*/
public Optional> diskIOPSReadOnly() {
return Optional.ofNullable(this.diskIOPSReadOnly);
}
/**
* The number of IOPS allowed for this disk; only settable for UltraSSD disks. One operation can transfer between 4k and 256k bytes.
*
*/
@Import(name="diskIOPSReadWrite")
private @Nullable Output diskIOPSReadWrite;
/**
* @return The number of IOPS allowed for this disk; only settable for UltraSSD disks. One operation can transfer between 4k and 256k bytes.
*
*/
public Optional> diskIOPSReadWrite() {
return Optional.ofNullable(this.diskIOPSReadWrite);
}
/**
* The total throughput (MBps) that will be allowed across all VMs mounting the shared disk as ReadOnly. MBps means millions of bytes per second - MB here uses the ISO notation, of powers of 10.
*
*/
@Import(name="diskMBpsReadOnly")
private @Nullable Output diskMBpsReadOnly;
/**
* @return The total throughput (MBps) that will be allowed across all VMs mounting the shared disk as ReadOnly. MBps means millions of bytes per second - MB here uses the ISO notation, of powers of 10.
*
*/
public Optional> diskMBpsReadOnly() {
return Optional.ofNullable(this.diskMBpsReadOnly);
}
/**
* 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.
*
*/
@Import(name="diskMBpsReadWrite")
private @Nullable Output diskMBpsReadWrite;
/**
* @return 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.
*
*/
public Optional> diskMBpsReadWrite() {
return Optional.ofNullable(this.diskMBpsReadWrite);
}
/**
* 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.
*
*/
@Import(name="diskName")
private @Nullable Output diskName;
/**
* @return 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.
*
*/
public Optional> diskName() {
return Optional.ofNullable(this.diskName);
}
/**
* If creationData.createOption is Empty, this field is mandatory and it indicates the size of the disk 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.
*
*/
@Import(name="diskSizeGB")
private @Nullable Output diskSizeGB;
/**
* @return If creationData.createOption is Empty, this field is mandatory and it indicates the size of the disk 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.
*
*/
public Optional> diskSizeGB() {
return Optional.ofNullable(this.diskSizeGB);
}
/**
* Encryption property can be used to encrypt data at rest with customer managed keys or platform managed keys.
*
*/
@Import(name="encryption")
private @Nullable Output encryption;
/**
* @return Encryption property can be used to encrypt data at rest with customer managed keys or platform managed keys.
*
*/
public Optional> encryption() {
return Optional.ofNullable(this.encryption);
}
/**
* Encryption settings collection used for Azure Disk Encryption, can contain multiple encryption settings per disk or snapshot.
*
*/
@Import(name="encryptionSettingsCollection")
private @Nullable Output encryptionSettingsCollection;
/**
* @return Encryption settings collection used for Azure Disk Encryption, can contain multiple encryption settings per disk or snapshot.
*
*/
public Optional> encryptionSettingsCollection() {
return Optional.ofNullable(this.encryptionSettingsCollection);
}
/**
* The extended location where the disk will be created. Extended location cannot be changed.
*
*/
@Import(name="extendedLocation")
private @Nullable Output extendedLocation;
/**
* @return The extended location where the disk will be created. Extended location cannot be changed.
*
*/
public Optional> extendedLocation() {
return Optional.ofNullable(this.extendedLocation);
}
/**
* The hypervisor generation of the Virtual Machine. Applicable to OS disks only.
*
*/
@Import(name="hyperVGeneration")
private @Nullable Output> hyperVGeneration;
/**
* @return The hypervisor generation of the Virtual Machine. Applicable to OS disks only.
*
*/
public Optional>> hyperVGeneration() {
return Optional.ofNullable(this.hyperVGeneration);
}
/**
* Resource location
*
*/
@Import(name="location")
private @Nullable Output location;
/**
* @return Resource location
*
*/
public Optional> location() {
return Optional.ofNullable(this.location);
}
/**
* The maximum number of VMs that can attach to the disk at the same time. Value greater than one indicates a disk that can be mounted on multiple VMs at the same time.
*
*/
@Import(name="maxShares")
private @Nullable Output maxShares;
/**
* @return The maximum number of VMs that can attach to the disk at the same time. Value greater than one indicates a disk that can be mounted on multiple VMs at the same time.
*
*/
public Optional> maxShares() {
return Optional.ofNullable(this.maxShares);
}
/**
* Policy for accessing the disk via network.
*
*/
@Import(name="networkAccessPolicy")
private @Nullable Output> networkAccessPolicy;
/**
* @return Policy for accessing the disk via network.
*
*/
public Optional>> networkAccessPolicy() {
return Optional.ofNullable(this.networkAccessPolicy);
}
/**
* Setting this property to true improves reliability and performance of data disks that are frequently (more than 5 times a day) by detached from one virtual machine and attached to another. This property should not be set for disks that are not detached and attached frequently as it causes the disks to not align with the fault domain of the virtual machine.
*
*/
@Import(name="optimizedForFrequentAttach")
private @Nullable Output optimizedForFrequentAttach;
/**
* @return Setting this property to true improves reliability and performance of data disks that are frequently (more than 5 times a day) by detached from one virtual machine and attached to another. This property should not be set for disks that are not detached and attached frequently as it causes the disks to not align with the fault domain of the virtual machine.
*
*/
public Optional> optimizedForFrequentAttach() {
return Optional.ofNullable(this.optimizedForFrequentAttach);
}
/**
* The Operating System type.
*
*/
@Import(name="osType")
private @Nullable Output osType;
/**
* @return The Operating System type.
*
*/
public Optional> osType() {
return Optional.ofNullable(this.osType);
}
/**
* Policy for controlling export on the disk.
*
*/
@Import(name="publicNetworkAccess")
private @Nullable Output> publicNetworkAccess;
/**
* @return Policy for controlling export on the disk.
*
*/
public Optional>> publicNetworkAccess() {
return Optional.ofNullable(this.publicNetworkAccess);
}
/**
* Purchase plan information for the the image from which the OS disk was created. E.g. - {name: 2019-Datacenter, publisher: MicrosoftWindowsServer, product: WindowsServer}
*
*/
@Import(name="purchasePlan")
private @Nullable Output purchasePlan;
/**
* @return Purchase plan information for the the image from which the OS disk was created. E.g. - {name: 2019-Datacenter, publisher: MicrosoftWindowsServer, product: WindowsServer}
*
*/
public Optional> purchasePlan() {
return Optional.ofNullable(this.purchasePlan);
}
/**
* The name of the resource group.
*
*/
@Import(name="resourceGroupName", required=true)
private Output resourceGroupName;
/**
* @return The name of the resource group.
*
*/
public Output resourceGroupName() {
return this.resourceGroupName;
}
/**
* Contains the security related information for the resource.
*
*/
@Import(name="securityProfile")
private @Nullable Output securityProfile;
/**
* @return Contains the security related information for the resource.
*
*/
public Optional> securityProfile() {
return Optional.ofNullable(this.securityProfile);
}
/**
* The disks sku name. Can be Standard_LRS, Premium_LRS, StandardSSD_LRS, UltraSSD_LRS, Premium_ZRS, StandardSSD_ZRS, or PremiumV2_LRS.
*
*/
@Import(name="sku")
private @Nullable Output sku;
/**
* @return The disks sku name. Can be Standard_LRS, Premium_LRS, StandardSSD_LRS, UltraSSD_LRS, Premium_ZRS, StandardSSD_ZRS, or PremiumV2_LRS.
*
*/
public Optional> sku() {
return Optional.ofNullable(this.sku);
}
/**
* List of supported capabilities for the image from which the OS disk was created.
*
*/
@Import(name="supportedCapabilities")
private @Nullable Output supportedCapabilities;
/**
* @return List of supported capabilities for the image from which the OS disk was created.
*
*/
public Optional> supportedCapabilities() {
return Optional.ofNullable(this.supportedCapabilities);
}
/**
* Indicates the OS on a disk supports hibernation.
*
*/
@Import(name="supportsHibernation")
private @Nullable Output supportsHibernation;
/**
* @return Indicates the OS on a disk supports hibernation.
*
*/
public Optional> supportsHibernation() {
return Optional.ofNullable(this.supportsHibernation);
}
/**
* Resource tags
*
*/
@Import(name="tags")
private @Nullable Output> tags;
/**
* @return Resource tags
*
*/
public Optional>> tags() {
return Optional.ofNullable(this.tags);
}
/**
* Performance tier of the disk (e.g, P4, S10) as described here: https://azure.microsoft.com/en-us/pricing/details/managed-disks/. Does not apply to Ultra disks.
*
*/
@Import(name="tier")
private @Nullable Output tier;
/**
* @return Performance tier of the disk (e.g, P4, S10) as described here: https://azure.microsoft.com/en-us/pricing/details/managed-disks/. Does not apply to Ultra disks.
*
*/
public Optional> tier() {
return Optional.ofNullable(this.tier);
}
/**
* The Logical zone list for Disk.
*
*/
@Import(name="zones")
private @Nullable Output> zones;
/**
* @return The Logical zone list for Disk.
*
*/
public Optional>> zones() {
return Optional.ofNullable(this.zones);
}
private DiskArgs() {}
private DiskArgs(DiskArgs $) {
this.burstingEnabled = $.burstingEnabled;
this.completionPercent = $.completionPercent;
this.creationData = $.creationData;
this.dataAccessAuthMode = $.dataAccessAuthMode;
this.diskAccessId = $.diskAccessId;
this.diskIOPSReadOnly = $.diskIOPSReadOnly;
this.diskIOPSReadWrite = $.diskIOPSReadWrite;
this.diskMBpsReadOnly = $.diskMBpsReadOnly;
this.diskMBpsReadWrite = $.diskMBpsReadWrite;
this.diskName = $.diskName;
this.diskSizeGB = $.diskSizeGB;
this.encryption = $.encryption;
this.encryptionSettingsCollection = $.encryptionSettingsCollection;
this.extendedLocation = $.extendedLocation;
this.hyperVGeneration = $.hyperVGeneration;
this.location = $.location;
this.maxShares = $.maxShares;
this.networkAccessPolicy = $.networkAccessPolicy;
this.optimizedForFrequentAttach = $.optimizedForFrequentAttach;
this.osType = $.osType;
this.publicNetworkAccess = $.publicNetworkAccess;
this.purchasePlan = $.purchasePlan;
this.resourceGroupName = $.resourceGroupName;
this.securityProfile = $.securityProfile;
this.sku = $.sku;
this.supportedCapabilities = $.supportedCapabilities;
this.supportsHibernation = $.supportsHibernation;
this.tags = $.tags;
this.tier = $.tier;
this.zones = $.zones;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(DiskArgs defaults) {
return new Builder(defaults);
}
public static final class Builder {
private DiskArgs $;
public Builder() {
$ = new DiskArgs();
}
public Builder(DiskArgs defaults) {
$ = new DiskArgs(Objects.requireNonNull(defaults));
}
/**
* @param burstingEnabled Set to true to enable bursting beyond the provisioned performance target of the disk. Bursting is disabled by default. Does not apply to Ultra disks.
*
* @return builder
*
*/
public Builder burstingEnabled(@Nullable Output burstingEnabled) {
$.burstingEnabled = burstingEnabled;
return this;
}
/**
* @param burstingEnabled Set to true to enable bursting beyond the provisioned performance target of the disk. Bursting is disabled by default. Does not apply to Ultra disks.
*
* @return builder
*
*/
public Builder burstingEnabled(Boolean burstingEnabled) {
return burstingEnabled(Output.of(burstingEnabled));
}
/**
* @param completionPercent Percentage complete for the background copy when a resource is created via the CopyStart operation.
*
* @return builder
*
*/
public Builder completionPercent(@Nullable Output completionPercent) {
$.completionPercent = completionPercent;
return this;
}
/**
* @param completionPercent Percentage complete for the background copy when a resource is created via the CopyStart operation.
*
* @return builder
*
*/
public Builder completionPercent(Double completionPercent) {
return completionPercent(Output.of(completionPercent));
}
/**
* @param creationData Disk source information. CreationData information cannot be changed after the disk has been created.
*
* @return builder
*
*/
public Builder creationData(Output creationData) {
$.creationData = creationData;
return this;
}
/**
* @param creationData Disk source information. CreationData information cannot be changed after the disk has been created.
*
* @return builder
*
*/
public Builder creationData(CreationDataArgs creationData) {
return creationData(Output.of(creationData));
}
/**
* @param dataAccessAuthMode Additional authentication requirements when exporting or uploading to a disk or snapshot.
*
* @return builder
*
*/
public Builder dataAccessAuthMode(@Nullable Output> dataAccessAuthMode) {
$.dataAccessAuthMode = dataAccessAuthMode;
return this;
}
/**
* @param dataAccessAuthMode Additional authentication requirements when exporting or uploading to a disk or snapshot.
*
* @return builder
*
*/
public Builder dataAccessAuthMode(Either dataAccessAuthMode) {
return dataAccessAuthMode(Output.of(dataAccessAuthMode));
}
/**
* @param dataAccessAuthMode Additional authentication requirements when exporting or uploading to a disk or snapshot.
*
* @return builder
*
*/
public Builder dataAccessAuthMode(String dataAccessAuthMode) {
return dataAccessAuthMode(Either.ofLeft(dataAccessAuthMode));
}
/**
* @param dataAccessAuthMode Additional authentication requirements when exporting or uploading to a disk or snapshot.
*
* @return builder
*
*/
public Builder dataAccessAuthMode(DataAccessAuthMode dataAccessAuthMode) {
return dataAccessAuthMode(Either.ofRight(dataAccessAuthMode));
}
/**
* @param diskAccessId ARM id of the DiskAccess resource for using private endpoints on disks.
*
* @return builder
*
*/
public Builder diskAccessId(@Nullable Output diskAccessId) {
$.diskAccessId = diskAccessId;
return this;
}
/**
* @param diskAccessId ARM id of the DiskAccess resource for using private endpoints on disks.
*
* @return builder
*
*/
public Builder diskAccessId(String diskAccessId) {
return diskAccessId(Output.of(diskAccessId));
}
/**
* @param diskIOPSReadOnly The total number of IOPS that will be allowed across all VMs mounting the shared disk as ReadOnly. One operation can transfer between 4k and 256k bytes.
*
* @return builder
*
*/
public Builder diskIOPSReadOnly(@Nullable Output diskIOPSReadOnly) {
$.diskIOPSReadOnly = diskIOPSReadOnly;
return this;
}
/**
* @param diskIOPSReadOnly The total number of IOPS that will be allowed across all VMs mounting the shared disk as ReadOnly. One operation can transfer between 4k and 256k bytes.
*
* @return builder
*
*/
public Builder diskIOPSReadOnly(Double diskIOPSReadOnly) {
return diskIOPSReadOnly(Output.of(diskIOPSReadOnly));
}
/**
* @param diskIOPSReadWrite The number of IOPS allowed for this disk; only settable for UltraSSD disks. One operation can transfer between 4k and 256k bytes.
*
* @return builder
*
*/
public Builder diskIOPSReadWrite(@Nullable Output diskIOPSReadWrite) {
$.diskIOPSReadWrite = diskIOPSReadWrite;
return this;
}
/**
* @param diskIOPSReadWrite The number of IOPS allowed for this disk; only settable for UltraSSD disks. One operation can transfer between 4k and 256k bytes.
*
* @return builder
*
*/
public Builder diskIOPSReadWrite(Double diskIOPSReadWrite) {
return diskIOPSReadWrite(Output.of(diskIOPSReadWrite));
}
/**
* @param diskMBpsReadOnly The total throughput (MBps) that will be allowed across all VMs mounting the shared disk as ReadOnly. MBps means millions of bytes per second - MB here uses the ISO notation, of powers of 10.
*
* @return builder
*
*/
public Builder diskMBpsReadOnly(@Nullable Output diskMBpsReadOnly) {
$.diskMBpsReadOnly = diskMBpsReadOnly;
return this;
}
/**
* @param diskMBpsReadOnly The total throughput (MBps) that will be allowed across all VMs mounting the shared disk as ReadOnly. MBps means millions of bytes per second - MB here uses the ISO notation, of powers of 10.
*
* @return builder
*
*/
public Builder diskMBpsReadOnly(Double diskMBpsReadOnly) {
return diskMBpsReadOnly(Output.of(diskMBpsReadOnly));
}
/**
* @param diskMBpsReadWrite 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.
*
* @return builder
*
*/
public Builder diskMBpsReadWrite(@Nullable Output diskMBpsReadWrite) {
$.diskMBpsReadWrite = diskMBpsReadWrite;
return this;
}
/**
* @param diskMBpsReadWrite 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.
*
* @return builder
*
*/
public Builder diskMBpsReadWrite(Double diskMBpsReadWrite) {
return diskMBpsReadWrite(Output.of(diskMBpsReadWrite));
}
/**
* @param diskName 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.
*
* @return builder
*
*/
public Builder diskName(@Nullable Output diskName) {
$.diskName = diskName;
return this;
}
/**
* @param diskName 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.
*
* @return builder
*
*/
public Builder diskName(String diskName) {
return diskName(Output.of(diskName));
}
/**
* @param diskSizeGB If creationData.createOption is Empty, this field is mandatory and it indicates the size of the disk 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.
*
* @return builder
*
*/
public Builder diskSizeGB(@Nullable Output diskSizeGB) {
$.diskSizeGB = diskSizeGB;
return this;
}
/**
* @param diskSizeGB If creationData.createOption is Empty, this field is mandatory and it indicates the size of the disk 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.
*
* @return builder
*
*/
public Builder diskSizeGB(Integer diskSizeGB) {
return diskSizeGB(Output.of(diskSizeGB));
}
/**
* @param encryption Encryption property can be used to encrypt data at rest with customer managed keys or platform managed keys.
*
* @return builder
*
*/
public Builder encryption(@Nullable Output encryption) {
$.encryption = encryption;
return this;
}
/**
* @param encryption Encryption property can be used to encrypt data at rest with customer managed keys or platform managed keys.
*
* @return builder
*
*/
public Builder encryption(EncryptionArgs encryption) {
return encryption(Output.of(encryption));
}
/**
* @param encryptionSettingsCollection Encryption settings collection used for Azure Disk Encryption, can contain multiple encryption settings per disk or snapshot.
*
* @return builder
*
*/
public Builder encryptionSettingsCollection(@Nullable Output encryptionSettingsCollection) {
$.encryptionSettingsCollection = encryptionSettingsCollection;
return this;
}
/**
* @param encryptionSettingsCollection Encryption settings collection used for Azure Disk Encryption, can contain multiple encryption settings per disk or snapshot.
*
* @return builder
*
*/
public Builder encryptionSettingsCollection(EncryptionSettingsCollectionArgs encryptionSettingsCollection) {
return encryptionSettingsCollection(Output.of(encryptionSettingsCollection));
}
/**
* @param extendedLocation The extended location where the disk will be created. Extended location cannot be changed.
*
* @return builder
*
*/
public Builder extendedLocation(@Nullable Output extendedLocation) {
$.extendedLocation = extendedLocation;
return this;
}
/**
* @param extendedLocation The extended location where the disk will be created. Extended location cannot be changed.
*
* @return builder
*
*/
public Builder extendedLocation(ExtendedLocationArgs extendedLocation) {
return extendedLocation(Output.of(extendedLocation));
}
/**
* @param hyperVGeneration The hypervisor generation of the Virtual Machine. Applicable to OS disks only.
*
* @return builder
*
*/
public Builder hyperVGeneration(@Nullable Output> hyperVGeneration) {
$.hyperVGeneration = hyperVGeneration;
return this;
}
/**
* @param hyperVGeneration The hypervisor generation of the Virtual Machine. Applicable to OS disks only.
*
* @return builder
*
*/
public Builder hyperVGeneration(Either hyperVGeneration) {
return hyperVGeneration(Output.of(hyperVGeneration));
}
/**
* @param hyperVGeneration The hypervisor generation of the Virtual Machine. Applicable to OS disks only.
*
* @return builder
*
*/
public Builder hyperVGeneration(String hyperVGeneration) {
return hyperVGeneration(Either.ofLeft(hyperVGeneration));
}
/**
* @param hyperVGeneration The hypervisor generation of the Virtual Machine. Applicable to OS disks only.
*
* @return builder
*
*/
public Builder hyperVGeneration(HyperVGeneration hyperVGeneration) {
return hyperVGeneration(Either.ofRight(hyperVGeneration));
}
/**
* @param location Resource location
*
* @return builder
*
*/
public Builder location(@Nullable Output location) {
$.location = location;
return this;
}
/**
* @param location Resource location
*
* @return builder
*
*/
public Builder location(String location) {
return location(Output.of(location));
}
/**
* @param maxShares The maximum number of VMs that can attach to the disk at the same time. Value greater than one indicates a disk that can be mounted on multiple VMs at the same time.
*
* @return builder
*
*/
public Builder maxShares(@Nullable Output maxShares) {
$.maxShares = maxShares;
return this;
}
/**
* @param maxShares The maximum number of VMs that can attach to the disk at the same time. Value greater than one indicates a disk that can be mounted on multiple VMs at the same time.
*
* @return builder
*
*/
public Builder maxShares(Integer maxShares) {
return maxShares(Output.of(maxShares));
}
/**
* @param networkAccessPolicy Policy for accessing the disk via network.
*
* @return builder
*
*/
public Builder networkAccessPolicy(@Nullable Output> networkAccessPolicy) {
$.networkAccessPolicy = networkAccessPolicy;
return this;
}
/**
* @param networkAccessPolicy Policy for accessing the disk via network.
*
* @return builder
*
*/
public Builder networkAccessPolicy(Either networkAccessPolicy) {
return networkAccessPolicy(Output.of(networkAccessPolicy));
}
/**
* @param networkAccessPolicy Policy for accessing the disk via network.
*
* @return builder
*
*/
public Builder networkAccessPolicy(String networkAccessPolicy) {
return networkAccessPolicy(Either.ofLeft(networkAccessPolicy));
}
/**
* @param networkAccessPolicy Policy for accessing the disk via network.
*
* @return builder
*
*/
public Builder networkAccessPolicy(NetworkAccessPolicy networkAccessPolicy) {
return networkAccessPolicy(Either.ofRight(networkAccessPolicy));
}
/**
* @param optimizedForFrequentAttach Setting this property to true improves reliability and performance of data disks that are frequently (more than 5 times a day) by detached from one virtual machine and attached to another. This property should not be set for disks that are not detached and attached frequently as it causes the disks to not align with the fault domain of the virtual machine.
*
* @return builder
*
*/
public Builder optimizedForFrequentAttach(@Nullable Output optimizedForFrequentAttach) {
$.optimizedForFrequentAttach = optimizedForFrequentAttach;
return this;
}
/**
* @param optimizedForFrequentAttach Setting this property to true improves reliability and performance of data disks that are frequently (more than 5 times a day) by detached from one virtual machine and attached to another. This property should not be set for disks that are not detached and attached frequently as it causes the disks to not align with the fault domain of the virtual machine.
*
* @return builder
*
*/
public Builder optimizedForFrequentAttach(Boolean optimizedForFrequentAttach) {
return optimizedForFrequentAttach(Output.of(optimizedForFrequentAttach));
}
/**
* @param osType The Operating System type.
*
* @return builder
*
*/
public Builder osType(@Nullable Output osType) {
$.osType = osType;
return this;
}
/**
* @param osType The Operating System type.
*
* @return builder
*
*/
public Builder osType(OperatingSystemTypes osType) {
return osType(Output.of(osType));
}
/**
* @param publicNetworkAccess Policy for controlling export on the disk.
*
* @return builder
*
*/
public Builder publicNetworkAccess(@Nullable Output> publicNetworkAccess) {
$.publicNetworkAccess = publicNetworkAccess;
return this;
}
/**
* @param publicNetworkAccess Policy for controlling export on the disk.
*
* @return builder
*
*/
public Builder publicNetworkAccess(Either publicNetworkAccess) {
return publicNetworkAccess(Output.of(publicNetworkAccess));
}
/**
* @param publicNetworkAccess Policy for controlling export on the disk.
*
* @return builder
*
*/
public Builder publicNetworkAccess(String publicNetworkAccess) {
return publicNetworkAccess(Either.ofLeft(publicNetworkAccess));
}
/**
* @param publicNetworkAccess Policy for controlling export on the disk.
*
* @return builder
*
*/
public Builder publicNetworkAccess(PublicNetworkAccess publicNetworkAccess) {
return publicNetworkAccess(Either.ofRight(publicNetworkAccess));
}
/**
* @param purchasePlan Purchase plan information for the the image from which the OS disk was created. E.g. - {name: 2019-Datacenter, publisher: MicrosoftWindowsServer, product: WindowsServer}
*
* @return builder
*
*/
public Builder purchasePlan(@Nullable Output purchasePlan) {
$.purchasePlan = purchasePlan;
return this;
}
/**
* @param purchasePlan Purchase plan information for the the image from which the OS disk was created. E.g. - {name: 2019-Datacenter, publisher: MicrosoftWindowsServer, product: WindowsServer}
*
* @return builder
*
*/
public Builder purchasePlan(PurchasePlanArgs purchasePlan) {
return purchasePlan(Output.of(purchasePlan));
}
/**
* @param resourceGroupName The name of the resource group.
*
* @return builder
*
*/
public Builder resourceGroupName(Output resourceGroupName) {
$.resourceGroupName = resourceGroupName;
return this;
}
/**
* @param resourceGroupName The name of the resource group.
*
* @return builder
*
*/
public Builder resourceGroupName(String resourceGroupName) {
return resourceGroupName(Output.of(resourceGroupName));
}
/**
* @param securityProfile Contains the security related information for the resource.
*
* @return builder
*
*/
public Builder securityProfile(@Nullable Output securityProfile) {
$.securityProfile = securityProfile;
return this;
}
/**
* @param securityProfile Contains the security related information for the resource.
*
* @return builder
*
*/
public Builder securityProfile(DiskSecurityProfileArgs securityProfile) {
return securityProfile(Output.of(securityProfile));
}
/**
* @param sku The disks sku name. Can be Standard_LRS, Premium_LRS, StandardSSD_LRS, UltraSSD_LRS, Premium_ZRS, StandardSSD_ZRS, or PremiumV2_LRS.
*
* @return builder
*
*/
public Builder sku(@Nullable Output sku) {
$.sku = sku;
return this;
}
/**
* @param sku The disks sku name. Can be Standard_LRS, Premium_LRS, StandardSSD_LRS, UltraSSD_LRS, Premium_ZRS, StandardSSD_ZRS, or PremiumV2_LRS.
*
* @return builder
*
*/
public Builder sku(DiskSkuArgs sku) {
return sku(Output.of(sku));
}
/**
* @param supportedCapabilities List of supported capabilities for the image from which the OS disk was created.
*
* @return builder
*
*/
public Builder supportedCapabilities(@Nullable Output supportedCapabilities) {
$.supportedCapabilities = supportedCapabilities;
return this;
}
/**
* @param supportedCapabilities List of supported capabilities for the image from which the OS disk was created.
*
* @return builder
*
*/
public Builder supportedCapabilities(SupportedCapabilitiesArgs supportedCapabilities) {
return supportedCapabilities(Output.of(supportedCapabilities));
}
/**
* @param supportsHibernation Indicates the OS on a disk supports hibernation.
*
* @return builder
*
*/
public Builder supportsHibernation(@Nullable Output supportsHibernation) {
$.supportsHibernation = supportsHibernation;
return this;
}
/**
* @param supportsHibernation Indicates the OS on a disk supports hibernation.
*
* @return builder
*
*/
public Builder supportsHibernation(Boolean supportsHibernation) {
return supportsHibernation(Output.of(supportsHibernation));
}
/**
* @param tags Resource tags
*
* @return builder
*
*/
public Builder tags(@Nullable Output> tags) {
$.tags = tags;
return this;
}
/**
* @param tags Resource tags
*
* @return builder
*
*/
public Builder tags(Map tags) {
return tags(Output.of(tags));
}
/**
* @param tier Performance tier of the disk (e.g, P4, S10) as described here: https://azure.microsoft.com/en-us/pricing/details/managed-disks/. Does not apply to Ultra disks.
*
* @return builder
*
*/
public Builder tier(@Nullable Output tier) {
$.tier = tier;
return this;
}
/**
* @param tier Performance tier of the disk (e.g, P4, S10) as described here: https://azure.microsoft.com/en-us/pricing/details/managed-disks/. Does not apply to Ultra disks.
*
* @return builder
*
*/
public Builder tier(String tier) {
return tier(Output.of(tier));
}
/**
* @param zones The Logical zone list for Disk.
*
* @return builder
*
*/
public Builder zones(@Nullable Output> zones) {
$.zones = zones;
return this;
}
/**
* @param zones The Logical zone list for Disk.
*
* @return builder
*
*/
public Builder zones(List zones) {
return zones(Output.of(zones));
}
/**
* @param zones The Logical zone list for Disk.
*
* @return builder
*
*/
public Builder zones(String... zones) {
return zones(List.of(zones));
}
public DiskArgs build() {
if ($.creationData == null) {
throw new MissingRequiredPropertyException("DiskArgs", "creationData");
}
if ($.resourceGroupName == null) {
throw new MissingRequiredPropertyException("DiskArgs", "resourceGroupName");
}
return $;
}
}
}