Giter Club home page Giter Club logo

codedeploywebsiteexamplewithcloudformation's Introduction

AWS Code Deploy Full Pipeline With Cloudformation Only - Website Example

This example extends the official AWS Tutorial on using cloud formation with s3 for automatic deployments. Instead of creating the instance, roles, security groups and installing the codedeploy agent yourself use cloudformation for everything.

Using cloudformation to do all the hard lifting:

  • Setting up EC2 instance for code deploy with code deploy agent installed
  • Setting up codedploy application and pipeline
  • Events for automatic run of codedeploy pipeline

You will be charged for creating AWS resources.

Manual

Just run the following 4 commands:

You only have to have an ec2 keypair for the instance, you have to specify the name of the keypair in the first command by replacing <Ec2KeyName> with the actual name and without <>.

  1. aws cloudformation create-stack --stack-name deployment-infra --template-body file://deployment-infra.yml --parameters "ParameterKey=KeyName,ParameterValue=<Ec2KeyName>" --capabilities CAPABILITY_IAM

  2. aws cloudformation create-stack --stack-name deployment-group --template-body file://deployment-group.yml --capabilities CAPABILITY_NAMED_IAM

  3. aws cloudformation create-stack --stack-name codepipeline-s3-events-yaml --template-body file://codepipeline-s3-events-yaml.yml --capabilities CAPABILITY_IAM

  4. aws cloudformation create-stack --stack-name codepipeline-s3-cloudtrail-yaml --template-body file://codepipeline-s3-cloudtrail-yaml.yml

Now simply download the demo application SampleApp_Linux.zip SampleApp_Linux.zip and upload it to the root of your codepipeline-s3-events-yaml-sourcebucket-xxx source bucket. The deployment will start automatically and you can browse the example webpage under http://<public_instance_ip>-

References

codedeploywebsiteexamplewithcloudformation's People

Contributors

matthias-herrmann avatar

Watchers

 avatar  avatar

Forkers

dreamz1974

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.