File Coverage

blib/lib/Paws/EC2/RunInstances.pm
Criterion Covered Total %
statement 12 12 100.0
branch n/a
condition n/a
subroutine 4 4 100.0
pod n/a
total 16 16 100.0


line stmt bran cond sub pod time code
1              
2             package Paws::EC2::RunInstances;
3 1     1   467 use Moose;
  1     2   4  
  1         9  
  2         940  
  2         6  
  2         13  
4             has AdditionalInfo => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'additionalInfo' );
5             has BlockDeviceMappings => (is => 'ro', isa => 'ArrayRef[Paws::EC2::BlockDeviceMapping]', traits => ['NameInRequest'], request_name => 'BlockDeviceMapping' );
6             has ClientToken => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'clientToken' );
7             has DisableApiTermination => (is => 'ro', isa => 'Bool', traits => ['NameInRequest'], request_name => 'disableApiTermination' );
8             has DryRun => (is => 'ro', isa => 'Bool', traits => ['NameInRequest'], request_name => 'dryRun' );
9             has EbsOptimized => (is => 'ro', isa => 'Bool', traits => ['NameInRequest'], request_name => 'ebsOptimized' );
10             has ElasticGpuSpecification => (is => 'ro', isa => 'ArrayRef[Paws::EC2::ElasticGpuSpecification]');
11             has IamInstanceProfile => (is => 'ro', isa => 'Paws::EC2::IamInstanceProfileSpecification', traits => ['NameInRequest'], request_name => 'iamInstanceProfile' );
12             has ImageId => (is => 'ro', isa => 'Str', required => 1);
13             has InstanceInitiatedShutdownBehavior => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'instanceInitiatedShutdownBehavior' );
14             has InstanceType => (is => 'ro', isa => 'Str');
15             has Ipv6AddressCount => (is => 'ro', isa => 'Int');
16             has Ipv6Addresses => (is => 'ro', isa => 'ArrayRef[Paws::EC2::InstanceIpv6Address]', traits => ['NameInRequest'], request_name => 'Ipv6Address' );
17             has KernelId => (is => 'ro', isa => 'Str');
18             has KeyName => (is => 'ro', isa => 'Str');
19             has MaxCount => (is => 'ro', isa => 'Int', required => 1);
20             has MinCount => (is => 'ro', isa => 'Int', required => 1);
21             has Monitoring => (is => 'ro', isa => 'Paws::EC2::RunInstancesMonitoringEnabled');
22             has NetworkInterfaces => (is => 'ro', isa => 'ArrayRef[Paws::EC2::InstanceNetworkInterfaceSpecification]', traits => ['NameInRequest'], request_name => 'networkInterface' );
23             has Placement => (is => 'ro', isa => 'Paws::EC2::Placement');
24             has PrivateIpAddress => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'privateIpAddress' );
25             has RamdiskId => (is => 'ro', isa => 'Str');
26             has SecurityGroupIds => (is => 'ro', isa => 'ArrayRef[Str|Undef]', traits => ['NameInRequest'], request_name => 'SecurityGroupId' );
27             has SecurityGroups => (is => 'ro', isa => 'ArrayRef[Str|Undef]', traits => ['NameInRequest'], request_name => 'SecurityGroup' );
28             has SubnetId => (is => 'ro', isa => 'Str');
29             has TagSpecifications => (is => 'ro', isa => 'ArrayRef[Paws::EC2::TagSpecification]', traits => ['NameInRequest'], request_name => 'TagSpecification' );
30             has UserData => (is => 'ro', isa => 'Str');
31              
32 1     1   6390 use MooseX::ClassAttribute;
  1     2   5  
  1         10  
  2         12286  
  2         4  
  2         15  
33              
34             class_has _api_call => (isa => 'Str', is => 'ro', default => 'RunInstances');
35             class_has _returns => (isa => 'Str', is => 'ro', default => 'Paws::EC2::Reservation');
36             class_has _result_key => (isa => 'Str', is => 'ro');
37             1;
38              
39             ### main pod documentation begin ###
40              
41             =head1 NAME
42              
43             Paws::EC2::RunInstances - Arguments for method RunInstances on Paws::EC2
44              
45             =head1 DESCRIPTION
46              
47             This class represents the parameters used for calling the method RunInstances on the
48             Amazon Elastic Compute Cloud service. Use the attributes of this class
49             as arguments to method RunInstances.
50              
51             You shouldn't make instances of this class. Each attribute should be used as a named argument in the call to RunInstances.
52              
53             As an example:
54              
55             $service_obj->RunInstances(Att1 => $value1, Att2 => $value2, ...);
56              
57             Values for attributes that are native types (Int, String, Float, etc) can passed as-is (scalar values). Values for complex Types (objects) can be passed as a HashRef. The keys and values of the hashref will be used to instance the underlying object.
58              
59             =head1 ATTRIBUTES
60              
61              
62             =head2 AdditionalInfo => Str
63              
64             Reserved.
65              
66              
67              
68             =head2 BlockDeviceMappings => ArrayRef[L<Paws::EC2::BlockDeviceMapping>]
69              
70             The block device mapping.
71              
72             Supplying both a snapshot ID and an encryption value as arguments for
73             block-device mapping results in an error. This is because only blank
74             volumes can be encrypted on start, and these are not created from a
75             snapshot. If a snapshot is the basis for the volume, it contains data
76             by definition and its encryption status cannot be changed using this
77             action.
78              
79              
80              
81             =head2 ClientToken => Str
82              
83             Unique, case-sensitive identifier you provide to ensure the idempotency
84             of the request. For more information, see Ensuring Idempotency.
85              
86             Constraints: Maximum 64 ASCII characters
87              
88              
89              
90             =head2 DisableApiTermination => Bool
91              
92             If you set this parameter to C<true>, you can't terminate the instance
93             using the Amazon EC2 console, CLI, or API; otherwise, you can. To
94             change this attribute to C<false> after launch, use
95             ModifyInstanceAttribute. Alternatively, if you set
96             C<InstanceInitiatedShutdownBehavior> to C<terminate>, you can terminate
97             the instance by running the shutdown command from the instance.
98              
99             Default: C<false>
100              
101              
102              
103             =head2 DryRun => Bool
104              
105             Checks whether you have the required permissions for the action,
106             without actually making the request, and provides an error response. If
107             you have the required permissions, the error response is
108             C<DryRunOperation>. Otherwise, it is C<UnauthorizedOperation>.
109              
110              
111              
112             =head2 EbsOptimized => Bool
113              
114             Indicates whether the instance is optimized for Amazon EBS I/O. This
115             optimization provides dedicated throughput to Amazon EBS and an
116             optimized configuration stack to provide optimal Amazon EBS I/O
117             performance. This optimization isn't available with all instance types.
118             Additional usage charges apply when using an EBS-optimized instance.
119              
120             Default: C<false>
121              
122              
123              
124             =head2 ElasticGpuSpecification => ArrayRef[L<Paws::EC2::ElasticGpuSpecification>]
125              
126             An Elastic GPU to associate with the instance.
127              
128              
129              
130             =head2 IamInstanceProfile => L<Paws::EC2::IamInstanceProfileSpecification>
131              
132             The IAM instance profile.
133              
134              
135              
136             =head2 B<REQUIRED> ImageId => Str
137              
138             The ID of the AMI, which you can get by calling DescribeImages.
139              
140              
141              
142             =head2 InstanceInitiatedShutdownBehavior => Str
143              
144             Indicates whether an instance stops or terminates when you initiate
145             shutdown from the instance (using the operating system command for
146             system shutdown).
147              
148             Default: C<stop>
149              
150             Valid values are: C<"stop">, C<"terminate">
151              
152             =head2 InstanceType => Str
153              
154             The instance type. For more information, see Instance Types in the
155             I<Amazon Elastic Compute Cloud User Guide>.
156              
157             Default: C<m1.small>
158              
159             Valid values are: C<"t1.micro">, C<"t2.nano">, C<"t2.micro">, C<"t2.small">, C<"t2.medium">, C<"t2.large">, C<"t2.xlarge">, C<"t2.2xlarge">, C<"m1.small">, C<"m1.medium">, C<"m1.large">, C<"m1.xlarge">, C<"m3.medium">, C<"m3.large">, C<"m3.xlarge">, C<"m3.2xlarge">, C<"m4.large">, C<"m4.xlarge">, C<"m4.2xlarge">, C<"m4.4xlarge">, C<"m4.10xlarge">, C<"m4.16xlarge">, C<"m2.xlarge">, C<"m2.2xlarge">, C<"m2.4xlarge">, C<"cr1.8xlarge">, C<"r3.large">, C<"r3.xlarge">, C<"r3.2xlarge">, C<"r3.4xlarge">, C<"r3.8xlarge">, C<"r4.large">, C<"r4.xlarge">, C<"r4.2xlarge">, C<"r4.4xlarge">, C<"r4.8xlarge">, C<"r4.16xlarge">, C<"x1.16xlarge">, C<"x1.32xlarge">, C<"x1e.32xlarge">, C<"i2.xlarge">, C<"i2.2xlarge">, C<"i2.4xlarge">, C<"i2.8xlarge">, C<"i3.large">, C<"i3.xlarge">, C<"i3.2xlarge">, C<"i3.4xlarge">, C<"i3.8xlarge">, C<"i3.16xlarge">, C<"hi1.4xlarge">, C<"hs1.8xlarge">, C<"c1.medium">, C<"c1.xlarge">, C<"c3.large">, C<"c3.xlarge">, C<"c3.2xlarge">, C<"c3.4xlarge">, C<"c3.8xlarge">, C<"c4.large">, C<"c4.xlarge">, C<"c4.2xlarge">, C<"c4.4xlarge">, C<"c4.8xlarge">, C<"cc1.4xlarge">, C<"cc2.8xlarge">, C<"g2.2xlarge">, C<"g2.8xlarge">, C<"g3.4xlarge">, C<"g3.8xlarge">, C<"g3.16xlarge">, C<"cg1.4xlarge">, C<"p2.xlarge">, C<"p2.8xlarge">, C<"p2.16xlarge">, C<"d2.xlarge">, C<"d2.2xlarge">, C<"d2.4xlarge">, C<"d2.8xlarge">, C<"f1.2xlarge">, C<"f1.16xlarge">
160              
161             =head2 Ipv6AddressCount => Int
162              
163             [EC2-VPC] A number of IPv6 addresses to associate with the primary
164             network interface. Amazon EC2 chooses the IPv6 addresses from the range
165             of your subnet. You cannot specify this option and the option to assign
166             specific IPv6 addresses in the same request. You can specify this
167             option if you've specified a minimum number of instances to launch.
168              
169              
170              
171             =head2 Ipv6Addresses => ArrayRef[L<Paws::EC2::InstanceIpv6Address>]
172              
173             [EC2-VPC] Specify one or more IPv6 addresses from the range of the
174             subnet to associate with the primary network interface. You cannot
175             specify this option and the option to assign a number of IPv6 addresses
176             in the same request. You cannot specify this option if you've specified
177             a minimum number of instances to launch.
178              
179              
180              
181             =head2 KernelId => Str
182              
183             The ID of the kernel.
184              
185             We recommend that you use PV-GRUB instead of kernels and RAM disks. For
186             more information, see PV-GRUB in the I<Amazon Elastic Compute Cloud
187             User Guide>.
188              
189              
190              
191             =head2 KeyName => Str
192              
193             The name of the key pair. You can create a key pair using CreateKeyPair
194             or ImportKeyPair.
195              
196             If you do not specify a key pair, you can't connect to the instance
197             unless you choose an AMI that is configured to allow users another way
198             to log in.
199              
200              
201              
202             =head2 B<REQUIRED> MaxCount => Int
203              
204             The maximum number of instances to launch. If you specify more
205             instances than Amazon EC2 can launch in the target Availability Zone,
206             Amazon EC2 launches the largest possible number of instances above
207             C<MinCount>.
208              
209             Constraints: Between 1 and the maximum number you're allowed for the
210             specified instance type. For more information about the default limits,
211             and how to request an increase, see How many instances can I run in
212             Amazon EC2 in the Amazon EC2 FAQ.
213              
214              
215              
216             =head2 B<REQUIRED> MinCount => Int
217              
218             The minimum number of instances to launch. If you specify a minimum
219             that is more instances than Amazon EC2 can launch in the target
220             Availability Zone, Amazon EC2 launches no instances.
221              
222             Constraints: Between 1 and the maximum number you're allowed for the
223             specified instance type. For more information about the default limits,
224             and how to request an increase, see How many instances can I run in
225             Amazon EC2 in the Amazon EC2 General FAQ.
226              
227              
228              
229             =head2 Monitoring => L<Paws::EC2::RunInstancesMonitoringEnabled>
230              
231             The monitoring for the instance.
232              
233              
234              
235             =head2 NetworkInterfaces => ArrayRef[L<Paws::EC2::InstanceNetworkInterfaceSpecification>]
236              
237             One or more network interfaces.
238              
239              
240              
241             =head2 Placement => L<Paws::EC2::Placement>
242              
243             The placement for the instance.
244              
245              
246              
247             =head2 PrivateIpAddress => Str
248              
249             [EC2-VPC] The primary IPv4 address. You must specify a value from the
250             IPv4 address range of the subnet.
251              
252             Only one private IP address can be designated as primary. You can't
253             specify this option if you've specified the option to designate a
254             private IP address as the primary IP address in a network interface
255             specification. You cannot specify this option if you're launching more
256             than one instance in the request.
257              
258              
259              
260             =head2 RamdiskId => Str
261              
262             The ID of the RAM disk.
263              
264             We recommend that you use PV-GRUB instead of kernels and RAM disks. For
265             more information, see PV-GRUB in the I<Amazon Elastic Compute Cloud
266             User Guide>.
267              
268              
269              
270             =head2 SecurityGroupIds => ArrayRef[Str|Undef]
271              
272             One or more security group IDs. You can create a security group using
273             CreateSecurityGroup.
274              
275             Default: Amazon EC2 uses the default security group.
276              
277              
278              
279             =head2 SecurityGroups => ArrayRef[Str|Undef]
280              
281             [EC2-Classic, default VPC] One or more security group names. For a
282             nondefault VPC, you must use security group IDs instead.
283              
284             Default: Amazon EC2 uses the default security group.
285              
286              
287              
288             =head2 SubnetId => Str
289              
290             [EC2-VPC] The ID of the subnet to launch the instance into.
291              
292              
293              
294             =head2 TagSpecifications => ArrayRef[L<Paws::EC2::TagSpecification>]
295              
296             The tags to apply to the resources during launch. You can tag instances
297             and volumes. The specified tags are applied to all instances or volumes
298             that are created during launch.
299              
300              
301              
302             =head2 UserData => Str
303              
304             The user data to make available to the instance. For more information,
305             see Running Commands on Your Linux Instance at Launch (Linux) and
306             Adding User Data (Windows). If you are using an AWS SDK or command line
307             tool, base64-encoding is performed for you, and you can load the text
308             from a file. Otherwise, you must provide base64-encoded text.
309              
310              
311              
312              
313             =head1 SEE ALSO
314              
315             This class forms part of L<Paws>, documenting arguments for method RunInstances in L<Paws::EC2>
316              
317             =head1 BUGS and CONTRIBUTIONS
318              
319             The source code is located here: https://github.com/pplu/aws-sdk-perl
320              
321             Please report bugs to: https://github.com/pplu/aws-sdk-perl/issues
322              
323             =cut
324