Implementing Modern DevOps
上QQ阅读APP看书,第一时间看更新

Launching an instance

The first thing you need to do is go to the AWS EC2 interface.

  1. Now click on the Launch Instance button, which will bring you to the following screen:
  1. This is where you can choose the image to run. As you can see, the image is the operating system that will run on top of the EC2 Instance. In Amazon jargon, this image is called Amazon Machine Image (AMI), and you can create your own ones and save them for later usage, allowing you to ship prebuilt software. For now, choose Ubuntu Server 16.04 by clicking on Select.
  2. The next screen is about the size of the image. AWS offers quite a big variety of sizes and types of images. This parameter drastically affects the performance of the application regarding the network, memory, and CPU performance as well as the I/O of the machine.
  3. Let’s look at the different types:
  1. As you can see, there is an instance for every necessity that the user can have. For now, we are going to choose a small instance first because we are just testing AWS and second because AWS has a free tier, which enables you to use the t2.micro instances for up to 1 year without any charge, as shown in the following screenshot:
  1. Now we have two options. Click on Review Instance Launch or Configure Instance Details. In this case, we are going to click on Review Instance Launch, but by clicking on Configure Instance Details, we can configure several elements of the instance, such as networking, storage, and so on.
  1. Once you click on Review Instance Launch, the review screen shows up. Click on Launch and you should get presented with something similar to what is shown in the following screenshot:
  1. Just assign a name to the key-pair name and click on the Download Key Pair button, which will download a .pem file that we will use later on to access via ssh to the instance.
  2. Once you have specified the key pair, click on Launch Instance, as shown in the preceding screenshot, and that's all. After a few checks, your image will be ready for installing the required software ( this usually takes a couple of minutes).

This is the bare minimum needed to create a running instance in AWS. As you can see, the full process is very well explained on the screen and in general, if you know the basics of DevOps (ssh, networking, and device management), you don't really need much help creating instances.