Getting started with AWS Cloud9
Tags: devtools, aws, cloud9, devops
Published: 2023-01-23 21:43:26

How do you maintain agility across several development projects with varied environment setup requirements? How do you learn and get hands-on with a new tool when you cannot install tools locally on your machine, either because you lack admin rights, the workstation cannot handle the added workload, or you simply don't want to?

Do you want to easily create and destroy environments as needed in minutes? AWS Cloud9 provides the solution to these challenges.

AWS Cloud9 is a powerful, cloud-based integrated development environment (IDE) that makes it easy for developers to write, run, and debug code in a web browser. With Cloud9, you can easily set up a development environment for your project, no matter what programming language you are using. 

In this blog post, I'll walk you through the steps to get started with AWS Cloud9.

**Step 1: Create an AWS account**
The first step to getting started with Cloud9 is to create an AWS account. If you already have an AWS account, you can skip this step. If not, you can sign up for a free account on the AWS website. Follow this [how-to guide](https://aws.amazon.com/premiumsupport/knowledge-center/create-and-activate-aws-account/) to get started.

**Step 2: Create an environment**
Once you have an AWS account, log in to the AWS Management Console and navigate to the Cloud9 service page. Click the "Create environment" button to create a new environment for your project. Give your environment a name and choose the settings that best suit your needs. You may create a new EC2 instance or use an existing one.
![Create Cloud9 Env: Name and Description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vg56fs8318wta5tajs8a.png)

![Create Cloud9 Env: Select Instance type and Platform](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kgev07e3zdyorw6ahhr2.png)
The instance type determines the capacity of the underlying EC2 instance in terms of vCPU and RAM. Select from the recommended list or access the list of additional instance types.
The Platform dictates the OS installed on the EC2 instance. There is also a default timeout of 30 minutes that helps to minimize the cost of running the EC2 instance.

![Create Cloud9 Env: Network Settings](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xht2l2sysbdidol0dp8e.png)
For the Network settings, you may select the AWS System Manager (SSM) option or the Secure Shell (SSH) option to assess the instance. SSH requires inbound ports, while SSM does not.

![Create Cloud9 Env: IAM Roles and Profile](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/owg58hgf224pd4ogbesj.png)
AWS handles automatic creation of the IAM roles and instance profile required based on your chosen configuration.
Click on Create, and you have a rich IDE created for you in minutes.

**Step 3: Do your thing: AKA Start coding**
Once your environment is created, you'll be taken to the IDE. Here, you can start writing code, running commands, and using the various tools provided by Cloud9. The IDE includes features such as code completion, debugging, and collaboration tools. You can also use the terminal in the IDE to run commands and interact with the underlying EC2 instance.


![Create Cloud9 Env: Start Coding](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/gchj7r6i4dusorwm005z.png)
**Step 4: Invite collaborators**
Cloud9 also allows you to invite other members to join your environment and collaborate with them. To invite someone to your environment, go to the "Share" button in the top right corner of the IDE and enter or create the IAM user(s) you wish to invite, and set permissions for the users.

![Invite collaborators](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/riv7csaa30nca3yhw9i3.png)

**Step 5: Terminate environment**
Once you are done with your development, you can stop your environment to save cost, and relaunch as needed. In any case, AWS hibernates the EC2 instance if idle for the selected timeout. Finally, terminate the environment.

To wrap up, even though the AWS console may change, this blogpost captures the general overview of getting up and running with AWS Cloud9: easily set up a cloud-based IDE development environment for your project, no matter what programming language you're using, and stop or terminate the environment whenever you please.

> Thank you for taking the time to read this blog post. If you find the article interesting, do like the article and connect with me on [LinkedIn](https://www.linkedin.com/in/obabawale).