Skip to content

Commit 2643155

Browse files
committed
Merge branch 'EronHennessey-doc_updates' into develop
* EronHennessey-doc_updates: Fix describe-vpc-peering-connection with correct filter syntax Fixed describe-reserved-instances with correct --filter syntax Correct syntax for describe-volumes example Update example to quote entire Key value Fixed unwieldy description in s3/_concepts.rst and the related subcommand test. re-added lines from commit fb84aaf Small correction to get-metric-statistics example Synced changes with doc team sources.
2 parents a66245c + 2b24bc0 commit 2643155

12 files changed

Lines changed: 76 additions & 54 deletions

awscli/examples/cloudwatch/get-metric-statistics.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
**To get the CPU utilization per EC2 instance**
22

33
The following example uses the ``get-metric-statistics`` command to get the CPU utilization for an EC2
4-
instance with the ID i-abcdef. For more examples using the ``get-metric-statistics`` command, see `Get Statistics for a Metric`_ in the *Amazon CloudWatch Developer Guide*.
4+
instance with the ID i-abcdef. For more examples using the ``get-metric-statistics`` command, see `Get Statistics for a Metric`__ in the *Amazon CloudWatch Developer Guide*.
55

6-
.. _`Get Statistics for a Metric`: http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/US_GetStatistics.html::
6+
.. __: http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/US_GetStatistics.html
7+
8+
::
79

810
aws cloudwatch get-metric-statistics --metric-name CPUUtilization --start-time 2014-04-08T23:18:00 --end-time 2014-04-09T23:18:00 --period 3600 --namespace AWS/EC2 --statistics Maximum --dimensions Name=InstanceId,Value=i-abcdef
911

awscli/examples/ec2/create-tags.rst

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,24 @@ This example adds (or overwrites) two tags for an AMI and an instance. One of th
1818

1919
Command::
2020

21-
aws ec2 create-tags --resources ami-1a2b3c4d i-10a64379 --tags Key=webserver,Value= Key=stack,Value=Production
21+
aws ec2 create-tags --resources ami-1a2b3c4d i-10a64379 --tags Key=webserver,Value= Key=stack,Value=Production
22+
23+
**To add tags with special characters**
24+
25+
This example adds the tag ``[Group]=test`` for an instance. The square brackets ([ and ]) are special characters, and must be escaped. If you are using Windows, surround the value with (\"):
26+
27+
Command::
28+
29+
aws ec2 create-tags --resources i-1a2b3c4d --tags Key=\"[Group]\",Value=test
30+
31+
If you are using Windows PowerShell, break out the characters with a backslash (\\), surround them with double quotes ("), and then surround the entire key and value structure with single quotes ('):
32+
33+
Command::
34+
35+
aws ec2 create-tags --resources i-1a2b3c4d --tags 'Key=\"[Group]\",Value=test'
36+
37+
If you are using Linux or OS X, enclose the entire key and value structure with single quotes ('), and then enclose the element with the special character with double quotes ("):
38+
39+
Command::
40+
41+
aws ec2 create-tags --resources i-1a2b3c4d --tags 'Key="[Group]",Value=test'

awscli/examples/ec2/describe-reserved-instances.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ This example filters the response to include only one-year, t1.micro Linux/UNIX
3737

3838
Command::
3939

40-
aws ec2 describe-reserved-instances --filters Name=duration,Values=31536000, Name=instance-type,Values=t1.micro, Name=product-description,Values=Linux/UNIX, Name=availability-zone,Values=us-west-1c
40+
aws ec2 describe-reserved-instances --filters Name=duration,Values=31536000 Name=instance-type,Values=t1.micro Name=product-description,Values=Linux/UNIX Name=availability-zone,Values=us-west-1c
4141

4242
Output::
4343

awscli/examples/ec2/describe-volumes.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ This example command describes all volumes that are both attached to the instanc
4949

5050
Command::
5151

52-
aws ec2 describe-volumes --region us-east-1 --filter Name=attachment.instance-id,Values=i-abe041d4 --filter Name=attachment.delete-on-termination,Values=true
52+
aws ec2 describe-volumes --region us-east-1 --filter Name=attachment.instance-id,Values=i-abe041d4 Name=attachment.delete-on-termination,Values=true
5353

5454
Output::
5555

@@ -75,4 +75,4 @@ Output::
7575
"Size": 8
7676
}
7777
]
78-
}
78+
}

awscli/examples/ec2/describe-vpc-peering-connections.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ This example describes all of your VPC peering connections that have the tag Nam
7373

7474
Command::
7575

76-
aws ec2 describe-vpc-peering-connections --filters Name=tag-key,Values=Name,Name=tag-value,Values=Finance,Accounts
76+
aws ec2 describe-vpc-peering-connections --filters Name=tag-key,Values=Name Name=tag-value,Values=Finance,Accounts
7777

7878

7979
This example describes all of the VPC peering connections you requested for the specified VPC, vpc-1a2b3c4d.

awscli/examples/emr/add-steps.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
**2. To add Streaming steps to a cluster**
2525

2626
- Command::
27-
27+
2828
aws emr add-steps --cluster-id j-XXXXXXXX --steps Type=STREAMING,Name='Streaming Program',ActionOnFailure=CONTINUE,Args=-mapper,mymapper,-reducer,myreducer,-input,myinput,-output,myoutput Type=STREAMING,Name='Streaming Program',ActionOnFailure=CONTINUE,Args=--files,s3://elasticmapreduce/samples/wordcount/wordSplitter.py,-mapper,wordSplitter.py,-reducer,aggregate,-input,s3://elasticmapreduce/samples/wordcount/input,-output,s3://mybucket/wordcount/output
2929

3030
- Required parameters::
@@ -49,7 +49,7 @@
4949

5050
- Command::
5151

52-
aws emr add-steps --cluster-id j-XXXXXXXX --steps Type=HIVE,Name='Hive program',ActionOnFailure=CONTINUE,Args=[-f,s3://mybuckey/myhivescript.q,-d,INPUT=s3://mybucket/myhiveinput,-d,OUTPUT=s3://mybucket/myhiveoutput,arg1,arg2] Type=HIVE,Name='Hive steps',ActionOnFailure=TERMINATE_CLUSTER,Args=[-f,s3://elasticmapreduce/samples/hive-ads/libs/model-build.q,-d,INPUT=s3://elasticmapreduce/samples/hive-ads/tables,-d,OUTPUT=s3://mybucket/hive-ads/output/2014-04-18/11-07-32,-d,LIBS=s3://elasticmapreduce/samples/hive-ads/libs]
52+
aws emr add-steps --cluster-id j-XXXXXXXX --steps Type=HIVE,Name='Hive program',ActionOnFailure=CONTINUE,Version=latest,Args=[-f,s3://mybuckey/myhivescript.q,-d,INPUT=s3://mybucket/myhiveinput,-d,OUTPUT=s3://mybucket/myhiveoutput,arg1,arg2] Type=HIVE,Name='Hive steps',ActionOnFailure=TERMINATE_CLUSTER,Version=latest,Args=[-f,s3://elasticmapreduce/samples/hive-ads/libs/model-build.q,-d,INPUT=s3://elasticmapreduce/samples/hive-ads/tables,-d,OUTPUT=s3://mybucket/hive-ads/output/2014-04-18/11-07-32,-d,LIBS=s3://elasticmapreduce/samples/hive-ads/libs]
5353

5454

5555
- Required parameters::
@@ -74,7 +74,7 @@
7474

7575
- Command::
7676

77-
aws emr add-steps --cluster-id j-XXXXXXXX --steps Type=PIG,Name='Pig program',ActionOnFailure=CONTINUE,Args=[-f,s3://mybuckey/mypigscript.pig,-p,INPUT=s3://mybucket/mypiginput,-p,OUTPUT=s3://mybucket/mypigoutput,arg1,arg2] Type=PIG,Name='Pig program',Args=[-f,s3://elasticmapreduce/samples/pig-apache/do-reports2.pig,-p,INPUT=s3://elasticmapreduce/samples/pig-apache/input,-p,OUTPUT=s3://mybucket/pig-apache/output,arg1,arg2]
77+
aws emr add-steps --cluster-id j-XXXXXXXX --steps Type=PIG,Name='Pig program',ActionOnFailure=CONTINUE,Version=latest,Args=[-f,s3://mybuckey/mypigscript.pig,-p,INPUT=s3://mybucket/mypiginput,-p,OUTPUT=s3://mybucket/mypigoutput,arg1,arg2] Type=PIG,Name='Pig program',Version=latest,Args=[-f,s3://elasticmapreduce/samples/pig-apache/do-reports2.pig,-p,INPUT=s3://elasticmapreduce/samples/pig-apache/input,-p,OUTPUT=s3://mybucket/pig-apache/output,arg1,arg2]
7878

7979

8080
- Required parameters::

awscli/examples/emr/add-tags.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,19 @@
1818

1919
[
2020
{
21-
"Value": "male",
21+
"Value": "male",
2222
"Key": "sex"
23-
},
23+
},
2424
{
25-
"Value": "123 East NW Seattle",
25+
"Value": "123 East NW Seattle",
2626
"Key": "address"
27-
},
27+
},
2828
{
29-
"Value": "John Doe",
29+
"Value": "John Doe",
3030
"Key": "name"
31-
},
31+
},
3232
{
33-
"Value": "29",
33+
"Value": "29",
3434
"Key": "age"
3535
}
3636
]

0 commit comments

Comments
 (0)