LinuxCommandLibrary

aws-cloud9

Manage AWS Cloud9 development environments

TLDR

List all Cloud9 development environment identifiers

$ aws cloud9 list-environments
copy

Create a Cloud9 development environment
$ aws cloud9 create-environment-ec2 --name [name] --instance-type [instance_type]
copy

Display information about Cloud9 development environments
$ aws cloud9 describe-environments --environment-ids [environment_ids]
copy

Add an environment member to a Cloud9 development environment
$ aws cloud9 create-environment-membership --environment-id [environment_id] --user-arn [user_arn] --permissions [permissions]
copy

Display status information for a Cloud9 development environment
$ aws cloud9 describe-environment-status --environment-id [environment_id]
copy

Delete a Cloud9 environment
$ aws cloud9 delete-environment --environment-id [environment_id]
copy

Delete an environment member from a development environment
$ aws cloud9 delete-environment-membership --environment-id [environment_id] --user-arn [user_arn]
copy

SYNOPSIS

aws cloud9 <subcommand> [global options] [--subcommand-options]

PARAMETERS

--debug
    Enable debug logging for troubleshooting.

--endpoint-url TEXT
    Custom endpoint URL for service.

--no-verify-ssl
    Disable SSL certificate verification.

--output TEXT
    Output format: json|text|table.

--profile TEXT
    Named profile from AWS config.

--query TEXT
    JMESPath query to filter output.

--region TEXT
    AWS region, e.g., us-east-1.

--version
    Show AWS CLI version.

--instance-type TEXT
    EC2 instance type for create-environment-ec2 (subcommand-specific).

--environment-name TEXT
    Name for new environment (subcommand-specific).

DESCRIPTION

aws cloud9 is a command within the AWS Command Line Interface (CLI) for interacting with AWS Cloud9, a cloud-based IDE service. It enables users to create, configure, monitor, and delete development environments directly from the terminal.

AWS Cloud9 provides a collaborative coding environment accessible via browser, pre-configured with development tools like editors, debuggers, and terminals. The CLI command supports key operations such as launching EC2-backed environments, listing active ones, updating memberships for team collaboration, tagging resources, and checking status.

Usage requires the AWS CLI (version 1 or 2) installed, configured with aws configure, and IAM permissions like cloud9:CreateEnvironmentEC2. Outputs are typically JSON, customizable via --output. It's ideal for automation, CI/CD pipelines, and infrastructure-as-code workflows with tools like Terraform or AWS CDK.

Common workflow: create an environment with aws cloud9 create-environment-ec2, share via aws cloud9 create-environment-membership, then access via browser URL returned in response.

CAVEATS

Requires AWS CLI installed/configured and IAM roles with Cloud9 permissions (e.g., Cloud9FullAccess). Not all regions supported; check AWS docs. EC2 environments incur compute costs. Subcommands have specific quotas/limits.

KEY SUBCOMMANDS

create-environment-ec2: Launch EC2 IDE.
list-environments: List all environments.
delete-environment: Terminate environment.
update-environment-membership: Manage user access.

AUTHENTICATION

Uses AWS credentials from ~/.aws/credentials, environment vars (AWS_ACCESS_KEY_ID), or IAM roles.

HISTORY

Introduced in 2017 with AWS Cloud9 public preview. Enhanced in 2019 for Lambda environments and team sharing. AWS CLI v2 (2020+) adds better performance and pagination support.

SEE ALSO

aws(1)

Copied to clipboard