pulumi_wasm_providers_azure_mini::compute::virtual_machine

Struct VirtualMachineArgsBuilder

source
pub struct VirtualMachineArgsBuilder<S: State = Empty> { /* private fields */ }
Expand description

Use builder syntax to set the inputs and finish with build_struct().

Implementations§

source§

impl<S: State> VirtualMachineArgsBuilder<S>

source

pub fn build_struct(self) -> VirtualMachineArgs
where S: IsComplete,

Finish building and return the requested object

source

pub fn additional_capabilities( self, value: impl Into<Output<Option<VirtualMachineAdditionalCapabilities>>>, ) -> VirtualMachineArgsBuilder<SetAdditionalCapabilities<S>>
where S::AdditionalCapabilities: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineAdditionalCapabilities>,
> as Default>::default()

An additional_capabilities block as defined below.

source

pub fn maybe_additional_capabilities( self, value: Option<impl Into<Output<Option<VirtualMachineAdditionalCapabilities>>>>, ) -> VirtualMachineArgsBuilder<SetAdditionalCapabilities<S>>
where S::AdditionalCapabilities: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineAdditionalCapabilities>,
> as Default>::default()

An additional_capabilities block as defined below.

source

pub fn availability_set_id( self, value: impl Into<Output<Option<String>>>, ) -> VirtualMachineArgsBuilder<SetAvailabilitySetId<S>>
where S::AvailabilitySetId: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

The ID of the Availability Set in which the Virtual Machine should exist. Changing this forces a new resource to be created.

source

pub fn maybe_availability_set_id( self, value: Option<impl Into<Output<Option<String>>>>, ) -> VirtualMachineArgsBuilder<SetAvailabilitySetId<S>>
where S::AvailabilitySetId: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

The ID of the Availability Set in which the Virtual Machine should exist. Changing this forces a new resource to be created.

source

pub fn boot_diagnostics( self, value: impl Into<Output<Option<VirtualMachineBootDiagnostics>>>, ) -> VirtualMachineArgsBuilder<SetBootDiagnostics<S>>
where S::BootDiagnostics: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineBootDiagnostics>,
> as Default>::default()

A boot_diagnostics block as defined below.

source

pub fn maybe_boot_diagnostics( self, value: Option<impl Into<Output<Option<VirtualMachineBootDiagnostics>>>>, ) -> VirtualMachineArgsBuilder<SetBootDiagnostics<S>>
where S::BootDiagnostics: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineBootDiagnostics>,
> as Default>::default()

A boot_diagnostics block as defined below.

source

pub fn delete_data_disks_on_termination( self, value: impl Into<Output<Option<bool>>>, ) -> VirtualMachineArgsBuilder<SetDeleteDataDisksOnTermination<S>>
where S::DeleteDataDisksOnTermination: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<bool>> as Default>::default().

Should the Data Disks (either the Managed Disks / VHD Blobs) be deleted when the Virtual Machine is destroyed? Defaults to false.

Note: This setting works when instance is deleted via the provider only and don’t forget to delete disks manually if you deleted VM manually. It can increase spending.

source

pub fn maybe_delete_data_disks_on_termination( self, value: Option<impl Into<Output<Option<bool>>>>, ) -> VirtualMachineArgsBuilder<SetDeleteDataDisksOnTermination<S>>
where S::DeleteDataDisksOnTermination: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<bool>> as Default>::default().

Should the Data Disks (either the Managed Disks / VHD Blobs) be deleted when the Virtual Machine is destroyed? Defaults to false.

Note: This setting works when instance is deleted via the provider only and don’t forget to delete disks manually if you deleted VM manually. It can increase spending.

source

pub fn delete_os_disk_on_termination( self, value: impl Into<Output<Option<bool>>>, ) -> VirtualMachineArgsBuilder<SetDeleteOsDiskOnTermination<S>>
where S::DeleteOsDiskOnTermination: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<bool>> as Default>::default().

Should the OS Disk (either the Managed Disk / VHD Blob) be deleted when the Virtual Machine is destroyed? Defaults to false.

Note: This setting works when instance is deleted via the provider only and don’t forget to delete disks manually if you deleted VM manually. It can increase spending.

source

pub fn maybe_delete_os_disk_on_termination( self, value: Option<impl Into<Output<Option<bool>>>>, ) -> VirtualMachineArgsBuilder<SetDeleteOsDiskOnTermination<S>>
where S::DeleteOsDiskOnTermination: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<bool>> as Default>::default().

Should the OS Disk (either the Managed Disk / VHD Blob) be deleted when the Virtual Machine is destroyed? Defaults to false.

Note: This setting works when instance is deleted via the provider only and don’t forget to delete disks manually if you deleted VM manually. It can increase spending.

source

pub fn identity( self, value: impl Into<Output<Option<VirtualMachineIdentity>>>, ) -> VirtualMachineArgsBuilder<SetIdentity<S>>
where S::Identity: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineIdentity>,
> as Default>::default()

An identity block as defined below.

source

pub fn maybe_identity( self, value: Option<impl Into<Output<Option<VirtualMachineIdentity>>>>, ) -> VirtualMachineArgsBuilder<SetIdentity<S>>
where S::Identity: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineIdentity>,
> as Default>::default()

An identity block as defined below.

source

pub fn license_type( self, value: impl Into<Output<Option<String>>>, ) -> VirtualMachineArgsBuilder<SetLicenseType<S>>
where S::LicenseType: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

Specifies the BYOL Type for this Virtual Machine. This is only applicable to Windows Virtual Machines. Possible values are Windows_Client and Windows_Server.

source

pub fn maybe_license_type( self, value: Option<impl Into<Output<Option<String>>>>, ) -> VirtualMachineArgsBuilder<SetLicenseType<S>>
where S::LicenseType: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

Specifies the BYOL Type for this Virtual Machine. This is only applicable to Windows Virtual Machines. Possible values are Windows_Client and Windows_Server.

source

pub fn location( self, value: impl Into<Output<Option<String>>>, ) -> VirtualMachineArgsBuilder<SetLocation<S>>
where S::Location: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

Specifies the Azure Region where the Virtual Machine exists. Changing this forces a new resource to be created.

source

pub fn maybe_location( self, value: Option<impl Into<Output<Option<String>>>>, ) -> VirtualMachineArgsBuilder<SetLocation<S>>
where S::Location: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

Specifies the Azure Region where the Virtual Machine exists. Changing this forces a new resource to be created.

source

pub fn name( self, value: impl Into<Output<Option<String>>>, ) -> VirtualMachineArgsBuilder<SetName<S>>
where S::Name: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

Specifies the name of the Virtual Machine. Changing this forces a new resource to be created.

source

pub fn maybe_name( self, value: Option<impl Into<Output<Option<String>>>>, ) -> VirtualMachineArgsBuilder<SetName<S>>
where S::Name: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

Specifies the name of the Virtual Machine. Changing this forces a new resource to be created.

source

pub fn network_interface_ids( self, value: impl Into<Output<Vec<String>>>, ) -> VirtualMachineArgsBuilder<SetNetworkInterfaceIds<S>>
where S::NetworkInterfaceIds: IsUnset,

Required.

A list of Network Interface IDs which should be associated with the Virtual Machine.

source

pub fn os_profile( self, value: impl Into<Output<Option<VirtualMachineOsProfile>>>, ) -> VirtualMachineArgsBuilder<SetOsProfile<S>>
where S::OsProfile: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineOsProfile>,
> as Default>::default()

An os_profile block as defined below. Required when create_option in the storage_os_disk block is set to FromImage.

source

pub fn maybe_os_profile( self, value: Option<impl Into<Output<Option<VirtualMachineOsProfile>>>>, ) -> VirtualMachineArgsBuilder<SetOsProfile<S>>
where S::OsProfile: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineOsProfile>,
> as Default>::default()

An os_profile block as defined below. Required when create_option in the storage_os_disk block is set to FromImage.

source

pub fn os_profile_linux_config( self, value: impl Into<Output<Option<VirtualMachineOsProfileLinuxConfig>>>, ) -> VirtualMachineArgsBuilder<SetOsProfileLinuxConfig<S>>
where S::OsProfileLinuxConfig: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineOsProfileLinuxConfig>,
> as Default>::default()

(Required, when a Linux machine) An os_profile_linux_config block as defined below.

source

pub fn maybe_os_profile_linux_config( self, value: Option<impl Into<Output<Option<VirtualMachineOsProfileLinuxConfig>>>>, ) -> VirtualMachineArgsBuilder<SetOsProfileLinuxConfig<S>>
where S::OsProfileLinuxConfig: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineOsProfileLinuxConfig>,
> as Default>::default()

(Required, when a Linux machine) An os_profile_linux_config block as defined below.

source

pub fn os_profile_secrets( self, value: impl Into<Output<Option<Vec<VirtualMachineOsProfileSecret>>>>, ) -> VirtualMachineArgsBuilder<SetOsProfileSecrets<S>>
where S::OsProfileSecrets: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<Vec<super::super::types::compute::VirtualMachineOsProfileSecret>>,
> as Default>::default()

One or more os_profile_secrets blocks as defined below.

source

pub fn maybe_os_profile_secrets( self, value: Option<impl Into<Output<Option<Vec<VirtualMachineOsProfileSecret>>>>>, ) -> VirtualMachineArgsBuilder<SetOsProfileSecrets<S>>
where S::OsProfileSecrets: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<Vec<super::super::types::compute::VirtualMachineOsProfileSecret>>,
> as Default>::default()

One or more os_profile_secrets blocks as defined below.

source

pub fn os_profile_windows_config( self, value: impl Into<Output<Option<VirtualMachineOsProfileWindowsConfig>>>, ) -> VirtualMachineArgsBuilder<SetOsProfileWindowsConfig<S>>
where S::OsProfileWindowsConfig: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineOsProfileWindowsConfig>,
> as Default>::default()

(Required, when a Windows machine) An os_profile_windows_config block as defined below.

source

pub fn maybe_os_profile_windows_config( self, value: Option<impl Into<Output<Option<VirtualMachineOsProfileWindowsConfig>>>>, ) -> VirtualMachineArgsBuilder<SetOsProfileWindowsConfig<S>>
where S::OsProfileWindowsConfig: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineOsProfileWindowsConfig>,
> as Default>::default()

(Required, when a Windows machine) An os_profile_windows_config block as defined below.

source

pub fn plan( self, value: impl Into<Output<Option<VirtualMachinePlan>>>, ) -> VirtualMachineArgsBuilder<SetPlan<S>>
where S::Plan: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachinePlan>,
> as Default>::default()

A plan block as defined below.

source

pub fn maybe_plan( self, value: Option<impl Into<Output<Option<VirtualMachinePlan>>>>, ) -> VirtualMachineArgsBuilder<SetPlan<S>>
where S::Plan: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachinePlan>,
> as Default>::default()

A plan block as defined below.

source

pub fn primary_network_interface_id( self, value: impl Into<Output<Option<String>>>, ) -> VirtualMachineArgsBuilder<SetPrimaryNetworkInterfaceId<S>>
where S::PrimaryNetworkInterfaceId: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

The ID of the Network Interface (which must be attached to the Virtual Machine) which should be the Primary Network Interface for this Virtual Machine.

source

pub fn maybe_primary_network_interface_id( self, value: Option<impl Into<Output<Option<String>>>>, ) -> VirtualMachineArgsBuilder<SetPrimaryNetworkInterfaceId<S>>
where S::PrimaryNetworkInterfaceId: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

The ID of the Network Interface (which must be attached to the Virtual Machine) which should be the Primary Network Interface for this Virtual Machine.

source

pub fn proximity_placement_group_id( self, value: impl Into<Output<Option<String>>>, ) -> VirtualMachineArgsBuilder<SetProximityPlacementGroupId<S>>
where S::ProximityPlacementGroupId: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

The ID of the Proximity Placement Group to which this Virtual Machine should be assigned. Changing this forces a new resource to be created

source

pub fn maybe_proximity_placement_group_id( self, value: Option<impl Into<Output<Option<String>>>>, ) -> VirtualMachineArgsBuilder<SetProximityPlacementGroupId<S>>
where S::ProximityPlacementGroupId: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

The ID of the Proximity Placement Group to which this Virtual Machine should be assigned. Changing this forces a new resource to be created

source

pub fn resource_group_name( self, value: impl Into<Output<String>>, ) -> VirtualMachineArgsBuilder<SetResourceGroupName<S>>
where S::ResourceGroupName: IsUnset,

Required.

Specifies the name of the Resource Group in which the Virtual Machine should exist. Changing this forces a new resource to be created.

source

pub fn storage_data_disks( self, value: impl Into<Output<Option<Vec<VirtualMachineStorageDataDisk>>>>, ) -> VirtualMachineArgsBuilder<SetStorageDataDisks<S>>
where S::StorageDataDisks: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<Vec<super::super::types::compute::VirtualMachineStorageDataDisk>>,
> as Default>::default()

One or more storage_data_disk blocks as defined below.

Please Note: Data Disks can also be attached either using this block or the azure.compute.DataDiskAttachment resource - but not both.

source

pub fn maybe_storage_data_disks( self, value: Option<impl Into<Output<Option<Vec<VirtualMachineStorageDataDisk>>>>>, ) -> VirtualMachineArgsBuilder<SetStorageDataDisks<S>>
where S::StorageDataDisks: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<Vec<super::super::types::compute::VirtualMachineStorageDataDisk>>,
> as Default>::default()

One or more storage_data_disk blocks as defined below.

Please Note: Data Disks can also be attached either using this block or the azure.compute.DataDiskAttachment resource - but not both.

source

pub fn storage_image_reference( self, value: impl Into<Output<Option<VirtualMachineStorageImageReference>>>, ) -> VirtualMachineArgsBuilder<SetStorageImageReference<S>>
where S::StorageImageReference: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineStorageImageReference>,
> as Default>::default()

A storage_image_reference block as defined below. Changing this forces a new resource to be created.

source

pub fn maybe_storage_image_reference( self, value: Option<impl Into<Output<Option<VirtualMachineStorageImageReference>>>>, ) -> VirtualMachineArgsBuilder<SetStorageImageReference<S>>
where S::StorageImageReference: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<super::super::types::compute::VirtualMachineStorageImageReference>,
> as Default>::default()

A storage_image_reference block as defined below. Changing this forces a new resource to be created.

source

pub fn storage_os_disk( self, value: impl Into<Output<VirtualMachineStorageOsDisk>>, ) -> VirtualMachineArgsBuilder<SetStorageOsDisk<S>>
where S::StorageOsDisk: IsUnset,

Required.

A storage_os_disk block as defined below.

source

pub fn tags( self, value: impl Into<Output<Option<HashMap<String, String>>>>, ) -> VirtualMachineArgsBuilder<SetTags<S>>
where S::Tags: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<std::collections::HashMap<String, String>>,
> as Default>::default()

A mapping of tags to assign to the Virtual Machine.

source

pub fn maybe_tags( self, value: Option<impl Into<Output<Option<HashMap<String, String>>>>>, ) -> VirtualMachineArgsBuilder<SetTags<S>>
where S::Tags: IsUnset,

Optional (Some / Option setters). Default:

<pulumi_wasm_rust::Output<
    Option<std::collections::HashMap<String, String>>,
> as Default>::default()

A mapping of tags to assign to the Virtual Machine.

source

pub fn vm_size( self, value: impl Into<Output<String>>, ) -> VirtualMachineArgsBuilder<SetVmSize<S>>
where S::VmSize: IsUnset,

Required.

Specifies the size of the Virtual Machine. See also Azure VM Naming Conventions.

source

pub fn zones( self, value: impl Into<Output<Option<String>>>, ) -> VirtualMachineArgsBuilder<SetZones<S>>
where S::Zones: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

A list of a single item of the Availability Zone which the Virtual Machine should be allocated in. Changing this forces a new resource to be created.

Please Note: Availability Zones are only supported in several regions at this time.

For more information on the different example configurations, please check out the Azure documentation

source

pub fn maybe_zones( self, value: Option<impl Into<Output<Option<String>>>>, ) -> VirtualMachineArgsBuilder<SetZones<S>>
where S::Zones: IsUnset,

Optional (Some / Option setters). Default: <pulumi_wasm_rust::Output<Option<String>> as Default>::default().

A list of a single item of the Availability Zone which the Virtual Machine should be allocated in. Changing this forces a new resource to be created.

Please Note: Availability Zones are only supported in several regions at this time.

For more information on the different example configurations, please check out the Azure documentation

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.