AWS SDK for .NET Documentation
CreateInstanceRequest Class
AmazonAmazon.OpsWorks.ModelCreateInstanceRequest Did this page help you?   Yes   No    Tell us about it...
Container for the parameters to the CreateInstance operation. Creates an instance in a specified stack. For more information, see Adding an Instance to a Layer.

Required Permissions: To use this action, an IAM user must have a Manage permissions level for the stack, or an attached policy that explicitly grants permissions. For more information on user permissions, see Managing User Permissions.

Declaration Syntax
C#
public class CreateInstanceRequest : AmazonWebServiceRequest
Members
All MembersConstructorsMethodsProperties



IconMemberDescription
CreateInstanceRequest()()()()
Initializes a new instance of the CreateInstanceRequest class

AmiId
Gets and sets the property AmiId.

A custom AMI ID to be used to create the instance. The AMI should be based on one of the standard AWS OpsWorks APIs: Amazon Linux or Ubuntu 12.04 LTS. For more information, see Instances


Architecture
Gets and sets the property Architecture.

The instance architecture. The default option is

CopyC#
x86_64
. Instance types do not necessarily support both architectures. For a list of the architectures that are supported by the different instance types, see Instance Families and Types.


AutoScalingType
Gets and sets the property AutoScalingType.

The instance auto scaling type, which has three possible values:

  • AlwaysRunning: A 24/7 instance, which is not affected by auto scaling.
  • TimeBasedAutoScaling: A time-based auto scaling instance, which is started and stopped based on a specified schedule. To specify the schedule, call SetTimeBasedAutoScaling.
  • LoadBasedAutoScaling: A load-based auto scaling instance, which is started and stopped based on load metrics. To use load-based auto scaling, you must enable it for the instance layer and configure the thresholds by calling SetLoadBasedAutoScaling.

AvailabilityZone
Gets and sets the property AvailabilityZone.

The instance Availability Zone. For more information, see Regions and Endpoints.


EbsOptimized
Gets and sets the property EbsOptimized.

Whether to create an Amazon EBS-optimized instance.


Equals(Object)
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
GetHashCode()()()()
Serves as a hash function for a particular type.
(Inherited from Object.)
GetType()()()()
Gets the type of the current instance.
(Inherited from Object.)
Hostname
Gets and sets the property Hostname.

The instance host name.


InstallUpdatesOnBoot
Gets and sets the property InstallUpdatesOnBoot.

Whether to install operating system and package updates when the instance boots. The default value is

CopyC#
true
. To control when updates are installed, set this value to
CopyC#
false
. You must then update your instances manually by using CreateDeployment to run the
CopyC#
update_dependencies
stack command or manually running
CopyC#
yum
(Amazon Linux) or
CopyC#
apt-get
(Ubuntu) on the instances.

Note:

We strongly recommend using the default value of

CopyC#
true
to ensure that your instances have the latest security updates.


InstanceType
Gets and sets the property InstanceType.

The instance type. AWS OpsWorks supports all instance types except Cluster Compute, Cluster GPU, and High Memory Cluster. For more information, see Instance Families and Types. The parameter values that you use to specify the various types are in the API Name column of the Available Instance Types table.


LayerIds
Gets and sets the property LayerIds.

An array that contains the instance layer IDs.


Os
Gets and sets the property Os.

The instance operating system, which must be set to one of the following.

  • Standard operating systems:
    CopyC#
    Amazon Linux
    or
    CopyC#
    Ubuntu
                12.04 LTS
  • Custom AMIs:
    CopyC#
    Custom

The default option is

CopyC#
Amazon Linux
. If you set this parameter to
CopyC#
Custom
, you must use the CreateInstance action's AmiId parameter to specify the custom AMI that you want to use. For more information on the standard operating systems, see Operating SystemsFor more information on how to use custom AMIs with OpsWorks, see Using Custom AMIs.


RootDeviceType
Gets and sets the property RootDeviceType.

The instance root device type. For more information, see Storage for the Root Device.


SshKeyName
Gets and sets the property SshKeyName.

The instance SSH key name.


StackId
Gets and sets the property StackId.

The stack ID.


SubnetId
Gets and sets the property SubnetId.

The ID of the instance's subnet. If the stack is running in a VPC, you can use this parameter to override the stack's default subnet ID value and direct AWS OpsWorks to launch the instance in a different subnet.


ToString()()()()
Returns a string that represents the current object.
(Inherited from Object.)
VirtualizationType
Gets and sets the property VirtualizationType.

The instance's virtualization type,

CopyC#
paravirtual
or
CopyC#
hvm
.


WithAmiId(String) Obsolete.
Sets the AmiId property

WithArchitecture(String) Obsolete.
Sets the Architecture property

WithAutoScalingType(String) Obsolete.
Sets the AutoScalingType property

WithAvailabilityZone(String) Obsolete.
Sets the AvailabilityZone property

WithEbsOptimized(Boolean) Obsolete.
Sets the EbsOptimized property

WithHostname(String) Obsolete.
Sets the Hostname property

WithInstallUpdatesOnBoot(Boolean) Obsolete.
Sets the InstallUpdatesOnBoot property

WithInstanceType(String) Obsolete.
Sets the InstanceType property

WithLayerIds(array<String>[]()[][]) Obsolete.
Sets the LayerIds property

WithLayerIds(IEnumerable<(Of <<'(String>)>>)) Obsolete.
Sets the LayerIds property

WithOs(String) Obsolete.
Sets the Os property

WithRootDeviceType(String) Obsolete.
Sets the RootDeviceType property

WithSshKeyName(String) Obsolete.
Sets the SshKeyName property

WithStackId(String) Obsolete.
Sets the StackId property

WithSubnetId(String) Obsolete.
Sets the SubnetId property

WithVirtualizationType(String) Obsolete.
Sets the VirtualizationType property

Inheritance Hierarchy
Object
AmazonWebServiceRequest
 CreateInstanceRequest

Assembly: AWSSDK (Module: AWSSDK) Version: 1.5.60.0 (1.5.60.0)