Amazon EC2 Command-Line Reference
The Amazon EC2 command-line tools are wrappers around the web services API. In fact, there is basically a one-to-one mapping between a command line, its arguments, and an API call of a similar name with similar parameters.
Every command has the following general form:
command[GENERAL OPTIONS] [COMMAND OPTIONS]
For example, the command to start an EC2 instance looks like this:
ec2-run-instances -v ami-123456 -g dmz
In this instance, the -v is a
general option for specifying verbose output, and ami-1234566 -g dmz are the command-specific
options.
The general options are:
-Pull in command parameters from standard input.
-CcertificateThe certificate to authenticate your web services request with Amazon. This value overrides the environment variable
EC2_CERT.--connection-timeoutIndicates an alternate SOAP connection timeout in seconds.
- -
-debug Prints out debug information.
--headersDisplay column headers.
--helpPrints out help for the command in question.
-KprivatekeyThe private key to authenticate your web services request with Amazon. This value overrides the environment variable
EC2_PRIVATE_KEY.--regionregionSpecifies the region to apply to the command.
--request-timeoutIndicates an alternate SOAP request timeout in seconds.
--show-empty-fieldsDisplays empty columns in command responses as
(nil).-UurlSpecifies the Amazon Web Services URL to make the API call against. This option overrides the
EC2_URLenvironment variable.-vIndicates that you would like verbose ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access