Have you ever struggled with long-running deployments that affect your business continuity and take valuable time away from your next project? There must be a better way!Establishing a CI/CD pipeline using AWS and the Serverless framework can drastically accelerate your deployments, and help eliminate human error during deployments. This means more uptime, less incidents in Production, and a better SLA with your customers.Establishing a robust CI/CD pipeline can also enable developers to focus on the next project, rather than preparing for and executing deployments. The bottom line is that your business can innovate faster with a great CI/CD process.
You will learn:
1. The benefits of setting up a CI/CD pipeline
2. Common CI/CD mistakes
3. How to set up a CI/CD pipeline using AWS and the Serverless framework
4. AWS services that can help you with build and deploy your code
5. How to use the serverless framework in combination with AWS to build and deploy code quickly
Who should attend:
• IT leaders who have had issues with business continuity due to deployments
• Developers looking to learn CI/CD best practices
• Anyone looking to learn the basics of CI/CD and why it is usefulReasons to attend:
• Quickly set up a CI/CD pipeline to accelerate your business’s digital growth
2. Overview
1. Big Compass Introduction
2. Deployment automation using AWS
3. Deployment automation using AWS + Serverless
4. CI/CD and Beyond
2
3. About Big Compass
● Boutique consulting firm
● Specializing in integration and related technologies
● We build connections
○ Systems
○ Apps
○ Corporations
○ People
3
5. Pain Points
● Long running deployments taking
large amount of effort
○ Time spent on deployments and not
innovation
● Errors deploying
● Difficult to replicate the
deployment to many instances
● Downtime on deployments
○ Lack of business continuity
5
9. Serverless Framework Introduction
● Open source framework allowing you to build and deploy apps
● Configuration written in YAML
● Similar to CloudFormation
● Includes a CLI
● Can deploy to AWS, Azure, GCP, and more
● When deploying to AWS, it uses CloudFormation under the hood
9
10. Uses for Serverless Framework
● Great for deploying serverless applications
● Speeds up deployment by automatically provisioning/mapping
● Can enable a multi-cloud strategy
● Local testing and mocks of cloud setup
10
11. Serverless Framework With AWS
● Build and deployment configuration housed in the Serverless YAML
● Serverless framework takes over your build and deploys your code
● Eliminates steps from your CodePipeline
11
14. Takeaways
● AWS + Serverless is awesome for
serverless applications
● AWS + Serverless only works in
certain scenarios
● A more diverse or hybrid system
may use CloudFormation,
Terraform, etc
● A combination of solutions may be
used
● Can split serverless deployments from
EC2, RDS, etc
● CI/CD is an evolutionary process
14
Plan
Design
ImplementTest
Deploy
16. Pain Points
● Bugs deployed to Production
● Difficult to regression test
● Labor-intensive QA cycle
slowing down releases
● Lack of understanding of use
cases
○ Lack of documentation
○ Difficult to test all scenarios
16
18. QA Automation Methodology
1. Well defined DevOps
2. Gather requirements
3. Capture QA test cases
4. Design automated testing suite
5. Implement functions to run
through all tests
6. Create a testing report
18
20. Automated Testing Considerations
● Unit testing
● Test-driven development
● UI testing
○ Cypress, Selenium, or other tools
○ Use tools to deliver a better
security posture
20
● Regression, load, and stress
testing
○ Implement reusable, automated
test suite
○ Potential to use tools like Postman
or JMeter
● Security testing
○ Probe for sensitive data
○ Create common attacks
○ Use tools to deliver a better
security posture
21. Automated Testing Considerations
● Changing requirements can mean altering automated testing suite
○ Design for this consideration to mitigate the risk
● Always run unit tests where possible
● CI/CD integration to automatically test before each deployment
21
23. Pain Points
● Account isolation
○ Environments
○ Customers
○ Tenants
● Difficult to sell SaaS solution
● Difficult to monetize
● Time taken to manually deploy to
new accounts
23
24. Account Creation Flow
1. Create new account
1. AWS Organizations +
CloudFormation
2. Update existing account
1. Use your CI/CD pipeline
24
25. Account Creation Considerations
● No one size fits all solution
● Monetization
● Versioning
● Updating all accounts vs. selectively updating
● Account management
● Account access
25
28. Next Steps
● Reach out to Aaron aaron@bigcompass.com
● Reach out to Jerry jerry.dixon@bigcompass.com
● Follow Big Compass on social media
● See you next time!
28
31. AWS Services Used - CodePipeline
● Triggered off of GitHub commit
○ Other triggers available
● Orchestration
● Flexible
● Visibility
● Leverage current process
31
32. AWS Services Used - CodeBuild
● Part of CodePipeline build
phase
● Build your code to prepare for
deployment
● Flexible
○ Execute custom commands
○ Prepare your deployment any
way you need it
32
33. AWS Services Used - Elastic Beanstalk
● Part of CodePipeline deploy
phase
● Allows for EC2 deployments
○ Includes auto scaling and load
balancing
33
Elastic Beanstalk
Lack deep AWS experience
Want/need to move quickly
Want to focus on code
CodeDeploy
Want to use shared hardware
Comfortable with AWS networking and permissions
Using EC2 to integrate with non-AWS services
I basically think of Elastic Beanstalk as a managed CodeDeploy using AWS Services. In most use cases Elastic Beanstalk will work, but for some mega corporations that want full control over their server and run agents for non-AWS services that need regular access/updates CodeDeploy offers that control.
CI/CD is cyclical and it’s an evolutionary process – don’t try to bite off everything at once
CI/CD is cyclical and it’s an evolutionary process – don’t try to bite off everything at once
This is the ultimate goal, but iterate to get there, and it all starts with a great CI/CD pipeline/process
Orchestration
Arrange your steps in whatever way you want. Define custom steps.
Pass outputs from one process to another seamlessly
Flexibility
Change the order of steps without creating a new pipeline
Easily integrate/deploy to a number of AWS Services based on what is right for your project
Pull in code from github/bitbucket/codecommit/etc
Visibility
Easily see the status of deployments
Quick high level troubleshooting
Quick links to logs for each step
Leverage Current Processes
Easily link a CodePipeline step to an existing business process
CodeBuild configurations
CodeDeploy deployment groups
Elastic Beanstalk configurations
CodePipeline isn’t about defining the steps, it’s about arranging them to create a functioning cicd pipeline.