AWS CodeDeploy – A Sample Walkthrough

14 / Nov / 2014 by Ishant Kumar 1 comments

AWS has unveiled several new services and tools to the existing AWS services at its re:Invent 2014 conference in Las Vegas.

In this blog, let’s take a closer look at AWS CodeDeploy, a brand new service aimed for code management and deployment and walk through the process of  setting up and deploying an application.

AWS CodeDeploy is a service that automates code deployments to Amazon EC2 instances. AWS CodeDeploy makes it easier for you to rapidly release new features, helps you avoid downtime during deployment, and handles the complexity of updating your applications. You can use AWS CodeDeploy to automate deployments, eliminating the need for error-prone manual operations, and the service scales with your infrastructure so you can easily deploy to one EC2 instance or thousands.

This service efficiently deploys your released code to a “fleet” of EC2 instances while taking care to leave as much of the fleet online as possible. It can accommodate fleets that range in size from one instance all the way up to tens of thousands of instance.

Benefits :

  • Automated Deployments
  • Minimize Downtime
  • Centralized Control
  • Easy To Adopt

Here are the step-by-step method to deploy a sample application.

1. Go To AWS Console and click on “CodeDeploy”. Click on “Get Started”.

code_deploy_start

2. On the Right Hand Side of screen – Click on “Create Deployment Walkthrough”.

codeDeploy0

3. Click on “Sample Deployment” and Click “Next”.

code_deploy1
4. Select Operating system as “Amazon Linux” and “Tag Key and Value” for your instance.

code_deploy2
5. Provide a name to your Application

code_deploy3

6. Select Revision Type .

code_deploy4
7. Name the Deployment Group.

code_deploy5

8. Select a Service Role.

code_deploy69. Choose a “Deployment Configuration”.

code_deploy7

10. Click on “Deploy Now”.

code_deploy8

11. Check the “Deployment Status”.

code_deploy9 12. Check the Deployment Details.

code_deploy10

13. You will see, new instance will be provisioned . It will take zip file from S3 and Deploy it on EC2 machines.

code_deploy11After deployment lets check by typing the EC2 public IP on browser.

code_deploy12

Code has been  deployed successfully.

  • Summary : On Amazon Linux Machine, AWS Code Deploy Agent downloads the sample bundle from S3. It consists your deployment build (index.html page in our case) and some configurations. It simple installs the httpd server and push the index.html file to /var/www/html/ directory.  If you want to install another web server say nginx , you can edit the file and upload the zip bundle to S3 . After that by creating a new Deployment Configuration, you would be able to deploy your build on another web server as well.

So this is how AWS has made easy the deployment process.  This was just a simple walkthrough, but you can explore more on

http://docs.aws.amazon.com/codedeploy/latest/userguide/welcome.html

References : http://aws.amazon.com/

Thanks
————————————–
Ishant Kumar
AWS Certified Solution Architect – Associate
AWS Administrator @ Intelligrape

FOUND THIS USEFUL? SHARE IT

comments (1 “AWS CodeDeploy – A Sample Walkthrough”)

  1. Pingback: AWS CodeDeploy Using S3 | TO THE NEW Blog

Leave a Reply

Your email address will not be published. Required fields are marked *