Book Image

Effective DevOps with AWS

By : Nathaniel Felsen
Book Image

Effective DevOps with AWS

By: Nathaniel Felsen

Overview of this book

The DevOps movement has transformed the way modern tech companies work. AWS which has been on the forefront of the Cloud computing revolution has also been a key contributor of this DevOps movement creating a huge range of managed services that help you implement the DevOps principles. In this book, you’ll see how the most successful tech start-ups launch and scale their services on AWS and how you can too. Written by a lead member of Mediums DevOps team, this book explains how to treat infrastructure as code, meaning you can bring resources online and offline as necessary with the code as easily as you control your software. You will also build a continuous integration and continuous deployment pipeline to keep your app up to date. You’ll find out how to scale your applications to offer maximum performance to users anywhere in the world, even when traffic spikes with the latest technologies, such as containers and serverless computing. You will also take a deep dive into monitoring and alerting to make sure your users have the best experience when using your service. Finally, you’ll get to grips with ensuring the security of your platform and data.
Table of Contents (9 chapters)

Using the EC2 container service

We just went over creating a Docker image for our application. We saw how easy and fast it is to start a container using Docker. This is a very transformative experience compared to using only virtual machine technologies, such as EC2.

One possibility that we haven't explicitly mentioned so far is that you can start multiple containers with the same image.

We can, for example, start our helloworld container five times, binding five different ports using the following command (adapt the ID based on the image ID you built. If needed, run docker images to find its ID):

$ for p in {3001..3005}; do docker run -d -p ${p}:3000 e7deb47c0528; done
32631a70b37ab827de39d57fd1d415339202779cf8e16963791980dc9212680a
ad69359b9630446700cbf515c67bd8d5e9de461542de7f6f0614045f36be427f
fad5b94bb1d10a31304348b086a95e0bb82d2ee944b3f75ce64b06af0ccf2353
cd0819ce968c497f9002b47a503f315d8494cb615e88b31029504bf6bd4f2630...