Skip to content
This repository was archived by the owner on May 10, 2024. It is now read-only.

Commit 773ce5e

Browse files
committed
Improve docs for EC2_run_image and Image_run
- Fill in missing parameter description - Include new instance types
1 parent 3c58865 commit 773ce5e

File tree

2 files changed

+79
-50
lines changed

2 files changed

+79
-50
lines changed

boto/ec2/connection.py

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -543,10 +543,11 @@ def run_instances(self, image_id, min_count=1, max_count=1,
543543
544544
:type security_groups: list of strings
545545
:param security_groups: The names of the security groups with which to
546-
associate instances
546+
associate instances.
547547
548548
:type user_data: string
549-
:param user_data: The user data passed to the launched instances
549+
:param user_data: The Base64-encoded MIME user data to be made
550+
available to the instance(s) in this reservation.
550551
551552
:type instance_type: string
552553
:param instance_type: The type of instance to run:
@@ -556,18 +557,22 @@ def run_instances(self, image_id, min_count=1, max_count=1,
556557
* m1.medium
557558
* m1.large
558559
* m1.xlarge
560+
* m3.xlarge
561+
* m3.2xlarge
559562
* c1.medium
560563
* c1.xlarge
561564
* m2.xlarge
562565
* m2.2xlarge
563566
* m2.4xlarge
567+
* cr1.8xlarge
568+
* hi1.4xlarge
569+
* hs1.8xlarge
564570
* cc1.4xlarge
565571
* cg1.4xlarge
566572
* cc2.8xlarge
567573
568574
:type placement: string
569-
:param placement: The availability zone in which to launch
570-
the instances.
575+
:param placement: The Availability Zone to launch the instance into.
571576
572577
:type kernel_id: string
573578
:param kernel_id: The ID of the kernel with which to launch the
@@ -593,7 +598,7 @@ def run_instances(self, image_id, min_count=1, max_count=1,
593598
594599
:type block_device_map: :class:`boto.ec2.blockdevicemapping.BlockDeviceMapping`
595600
:param block_device_map: A BlockDeviceMapping data structure
596-
describing the EBS volumes associated with the Image.
601+
describing the EBS volumes associated with the Image.
597602
598603
:type disable_api_termination: bool
599604
:param disable_api_termination: If True, the instances will be locked
@@ -613,7 +618,7 @@ def run_instances(self, image_id, min_count=1, max_count=1,
613618
614619
:type client_token: string
615620
:param client_token: Unique, case-sensitive identifier you provide
616-
to ensure idempotency of the request. Maximum 64 ASCII characters.
621+
to ensure idempotency of the request. Maximum 64 ASCII characters.
617622
618623
:type security_group_ids: list of strings
619624
:param security_group_ids: The ID of the VPC security groups with

boto/ec2/image.py

Lines changed: 68 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -174,87 +174,111 @@ def run(self, min_count=1, max_count=1, key_name=None,
174174
:param max_count: The maximum number of instances to start
175175
176176
:type key_name: string
177-
:param key_name: The name of the keypair to run this instance with.
177+
:param key_name: The name of the key pair with which to
178+
launch instances.
178179
179-
:type security_groups:
180-
:param security_groups:
180+
:type security_groups: list of strings
181+
:param security_groups: The names of the security groups with which to
182+
associate instances.
181183
182-
:type user_data:
183-
:param user_data:
184-
185-
:type addressing_type:
186-
:param addressing_type:
184+
:type user_data: string
185+
:param user_data: The Base64-encoded MIME user data to be made
186+
available to the instance(s) in this reservation.
187187
188188
:type instance_type: string
189-
:param instance_type: The type of instance to run. Current choices are:
190-
m1.small | m1.large | m1.xlarge | c1.medium |
191-
c1.xlarge | m2.xlarge | m2.2xlarge |
192-
m2.4xlarge | cc1.4xlarge
189+
:param instance_type: The type of instance to run:
190+
191+
* t1.micro
192+
* m1.small
193+
* m1.medium
194+
* m1.large
195+
* m1.xlarge
196+
* m3.xlarge
197+
* m3.2xlarge
198+
* c1.medium
199+
* c1.xlarge
200+
* m2.xlarge
201+
* m2.2xlarge
202+
* m2.4xlarge
203+
* cr1.8xlarge
204+
* hi1.4xlarge
205+
* hs1.8xlarge
206+
* cc1.4xlarge
207+
* cg1.4xlarge
208+
* cc2.8xlarge
193209
194210
:type placement: string
195-
:param placement: The availability zone in which to launch the instances
211+
:param placement: The Availability Zone to launch the instance into.
196212
197213
:type kernel_id: string
198-
:param kernel_id: The ID of the kernel with which to launch the instances
214+
:param kernel_id: The ID of the kernel with which to launch the
215+
instances.
199216
200217
:type ramdisk_id: string
201-
:param ramdisk_id: The ID of the RAM disk with which to launch the instances
218+
:param ramdisk_id: The ID of the RAM disk with which to launch the
219+
instances.
202220
203221
:type monitoring_enabled: bool
204-
:param monitoring_enabled: Enable CloudWatch monitoring on the instance.
222+
:param monitoring_enabled: Enable CloudWatch monitoring on
223+
the instance.
205224
206-
:type subnet_id: string
207-
:param subnet_id: The subnet ID within which to launch the instances for VPC.
225+
:type subnet_id: string
226+
:param subnet_id: The subnet ID within which to launch the instances
227+
for VPC.
208228
209229
:type private_ip_address: string
210-
:param private_ip_address: If you're using VPC, you can optionally use
211-
this parameter to assign the instance a
212-
specific available IP address from the
213-
subnet (e.g., 10.0.0.25).
230+
:param private_ip_address: If you're using VPC, you can
231+
optionally use this parameter to assign the instance a
232+
specific available IP address from the subnet (e.g.,
233+
10.0.0.25).
214234
215235
:type block_device_map: :class:`boto.ec2.blockdevicemapping.BlockDeviceMapping`
216236
:param block_device_map: A BlockDeviceMapping data structure
217-
describing the EBS volumes associated
218-
with the Image.
237+
describing the EBS volumes associated with the Image.
219238
220239
:type disable_api_termination: bool
221240
:param disable_api_termination: If True, the instances will be locked
222-
and will not be able to be terminated
223-
via the API.
241+
and will not be able to be terminated via the API.
224242
225243
:type instance_initiated_shutdown_behavior: string
226-
:param instance_initiated_shutdown_behavior: Specifies whether the instance
227-
stops or terminates on instance-initiated
228-
shutdown. Valid values are:
229-
stop | terminate
244+
:param instance_initiated_shutdown_behavior: Specifies whether the
245+
instance stops or terminates on instance-initiated shutdown.
246+
Valid values are:
247+
248+
* stop
249+
* terminate
230250
231251
:type placement_group: string
232252
:param placement_group: If specified, this is the name of the placement
233-
group in which the instance(s) will be launched.
253+
group in which the instance(s) will be launched.
234254
235255
:type additional_info: string
236-
:param additional_info: Specifies additional information to make
237-
available to the instance(s)
256+
:param additional_info: Specifies additional information to make
257+
available to the instance(s).
238258
239-
:type security_group_ids:
240-
:param security_group_ids:
259+
:type security_group_ids: list of strings
260+
:param security_group_ids: The ID of the VPC security groups with
261+
which to associate instances.
241262
242263
:type instance_profile_name: string
243-
:param instance_profile_name: The name of an IAM instance profile to use.
264+
:param instance_profile_name: The name of
265+
the IAM Instance Profile (IIP) to associate with the instances.
244266
245267
:type instance_profile_arn: string
246-
:param instance_profile_arn: The ARN of an IAM instance profile to use.
268+
:param instance_profile_arn: The Amazon resource name (ARN) of
269+
the IAM Instance Profile (IIP) to associate with the instances.
247270
248271
:type tenancy: string
249-
:param tenancy: The tenancy of the instance you want to launch. An
250-
instance with a tenancy of 'dedicated' runs on
251-
single-tenant hardware and can only be launched into a
252-
VPC. Valid values are: "default" or "dedicated".
253-
NOTE: To use dedicated tenancy you MUST specify a VPC
254-
subnet-ID as well.
272+
:param tenancy: The tenancy of the instance you want to
273+
launch. An instance with a tenancy of 'dedicated' runs on
274+
single-tenant hardware and can only be launched into a
275+
VPC. Valid values are:"default" or "dedicated".
276+
NOTE: To use dedicated tenancy you MUST specify a VPC
277+
subnet-ID as well.
255278
256279
:rtype: Reservation
257-
:return: The :class:`boto.ec2.instance.Reservation` associated with the request for machines
280+
:return: The :class:`boto.ec2.instance.Reservation` associated with
281+
the request for machines
258282
259283
"""
260284

0 commit comments

Comments
 (0)