Saturday, 22 February 2020

Using The AWS Command Line Interface (AWS CLI) - Part 5

Command Structure in the AWS CLI
The AWS Command Line Interface (AWS CLI) uses a multipart structure on the command line that must be specified in this order:
  1. The base call to the aws program.
  2. The top-level command, which typically corresponds to an AWS service supported by the AWS CLI. Like - sns, sqs etc.
  3. The subcommand that specifies which operation to perform.
  4. General CLI options or parameters required by the operation. You can specify these in any order as long as they follow the first three parts. If an exclusive parameter is specified multiple times, only the last value applies.
$ aws <command> <subcommand> [options and parameters]
Parameters can take various types of input values, such as numbers, strings, lists, maps, and JSON structures. What is supported is dependent upon the command and subcommand you specify.

Getting Help with the AWS CLI
You can get help with any command when using the AWS Command Line Interface (AWS CLI). To do so, simply type help at the end of a command name.

For example, the following command displays help for the general AWS CLI options and the available top-level commands.
$ aws help
The following command displays the available Amazon Elastic Compute Cloud (Amazon EC2) specific commands.
$ aws ec2 help

No comments:

Post a Comment