[ aws . cloud9 ]

create-environment-ec2

Description

Creates an AWS Cloud9 development environment, launches an Amazon Elastic Compute Cloud (Amazon EC2) instance, and then connects from the instance to the environment.

See also: AWS API Documentation

See ‘aws help’ for descriptions of global parameters.

Synopsis

  create-environment-ec2
--name <value>
[--description <value>]
[--client-request-token <value>]
--instance-type <value>
[--subnet-id <value>]
[--automatic-stop-time-minutes <value>]
[--owner-arn <value>]
[--tags <value>]
[--cli-input-json | --cli-input-yaml]
[--generate-cli-skeleton <value>]
[--cli-auto-prompt <value>]

Options

--name (string)

The name of the environment to create.

This name is visible to other AWS IAM users in the same AWS account.

--description (string)

The description of the environment to create.

--client-request-token (string)

A unique, case-sensitive string that helps AWS Cloud9 to ensure this operation completes no more than one time.

For more information, see Client Tokens in the Amazon EC2 API Reference .

--instance-type (string)

The type of instance to connect to the environment (for example, t2.micro ).

--subnet-id (string)

The ID of the subnet in Amazon VPC that AWS Cloud9 will use to communicate with the Amazon EC2 instance.

--automatic-stop-time-minutes (integer)

The number of minutes until the running instance is shut down after the environment has last been used.

--owner-arn (string)

The Amazon Resource Name (ARN) of the environment owner. This ARN can be the ARN of any AWS IAM principal. If this value is not specified, the ARN defaults to this environment’s creator.

--tags (list)

An array of key-value pairs that will be associated with the new AWS Cloud9 development environment.

(structure)

Metadata that is associated with AWS resources. In particular, a name-value pair that can be associated with an AWS Cloud9 development environment. There are two types of tags: user tags and system tags . A user tag is created by the user. A system tag is automatically created by AWS services. A system tag is prefixed with “aws:” and cannot be modified by the user.

Key -> (string)

The name part of a tag.

Value -> (string)

The value part of a tag.

Shorthand Syntax:

Key=string,Value=string ...

JSON Syntax:

[
  {
    "Key": "string",
    "Value": "string"
  }
  ...
]

--cli-input-json | --cli-input-yaml (string) Reads arguments from the JSON string provided. The JSON string follows the format provided by --generate-cli-skeleton. If other arguments are provided on the command line, those values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally. This may not be specified along with --cli-input-yaml.

--generate-cli-skeleton (string) Prints a JSON skeleton to standard output without sending an API request. If provided with no value or the value input, prints a sample input JSON that can be used as an argument for --cli-input-json. Similarly, if provided yaml-input it will print a sample input YAML that can be used with --cli-input-yaml. If provided with the value output, it validates the command inputs and returns a sample output JSON for that command.

--cli-auto-prompt (boolean) Automatically prompt for CLI input parameters.

See ‘aws help’ for descriptions of global parameters.

Examples

To create an AWS Cloud9 EC2 development environment

This example creates an AWS Cloud9 development environment with the specified settings, launches an Amazon Elastic Compute Cloud (Amazon EC2) instance, and then connects from the instance to the environment.

Command:

aws cloud9 create-environment-ec2 --name my-demo-env --description "My demonstration development environment." --instance-type t2.micro --subnet-id subnet-1fab8aEX --automatic-stop-time-minutes 60 --owner-arn arn:aws:iam::123456789012:user/MyDemoUser

Output:

{
  "environmentId": "8a34f51ce1e04a08882f1e811bd706EX"
}

Output

environmentId -> (string)

The ID of the environment that was created.