Please enable JavaScript.
Coggle requires JavaScript to display documents.
Automation - Coggle Diagram
Automation
Elastic Beanstalk
Elastic Beanstalk is AWS PaaS solution
1 Automation, you can templetize what you'd like your environment to look like
2 Deployment, it deploys your code for you in different environment
3 Management, it automatically handles:
- the building out the inside of your EC2 for you
- capacity provisioning
- load balancing
- scaling
- application health monitoring for your applications (metrics, event and you can create alert)
Exam Tips:
- Scenarios that are looking for simple one-stop solution
- PaaS: Beanstalk automated infra and code deployment
- Platform Types: supports Docker, Windows and Linux as well many different runtime engine
- For simpler web app: it is a good service to start with but you may face limitations for complex and large app
- Traditional it is not serverless, it is just creating an EC2 architecture
PaaS is a single-stop application deployment model. You bring your code, and the provider builds everything for you, deploys your application and then manages it
web server environment - an application that serves HTTP requests
worker environment - an environment that pulls tasks from an Amazon SQS queue
Environment Types
-
Load-balancing, Autoscaling Environment – automatically starts additional instances to accommodate increasing load on your application
Deployment
- All at once - Deploy the new version to all instances simultaneously. All instances in your environment are out of service for a short time while the deployment occurs
- Rolling - Deploy the new version in batches. Each batch is taken out of service during the deployment phase, reducing your environment's capacity by the number of instances in a batch
- Rolling with additional batch - (maintains full capacity) Deploy the new version in batches, but first launch a new batch of instances to ensure full capacity during the deployment process
- Immutable - (maintains full capacity) Deploy a full set of new instances running the new version of the application in a separate Auto Scaling group, alongside of the old version instances -> Blue/Green
- Traffic splitting - Deploy the new version to a fresh group of instances and temporarily split incoming client traffic between the existing application version and the new one (let you perform canary testing as part of your application deployment) -> Canary
CloudFormation
1 Write the template - It is a declarative programming language. It supports either JSON or YAML formatting
2 Deploy the template - when you do it, CloudFormation will go through the process of making the needed AWS API calls on your behalf
Exam Tips:
- CloudFormation is perfect for creating immutable architecture and make it simple destruction as well
- The consistency is something you'll want to keep in mind during the exam
- Basics: need to know parameters, mapping and resource and outputs sections
- Cross-Region: hard-coded values and resource IDs (e.g. AMI IDs) can be the reason templates fail to create
- Troubleshooting: if it finds an error, CloudFormation rolls back to the last known good state (no half backed stacks)
- It is just API calls: CloudFormation makes the same API calls you make manually
- Immutable: CloudFormation can easily create and destroy your entire architecture
- Template - Describes resources, attributes, dependencies and their intended state
- Change Set - Describes an execution plan to implement the intended state of a stack’s resources
- Stack - A group of resources and their intended states
- StackSet - A group of stacks across accounts and regions
- Resources- Define resources to create/update, supports > 500 resource types and allows for customer resources. Only template section that is not optional
- Parameters - Enable you to input custom values to your template each time you create or update a stack (with input validation and restriction). Support some native parameters types including SSM types. Use the Ref intrinsic function to reference "BucketName": {"Ref": "S3NameParam"}. Use Dynamic References to retrieves property values directly from AWS Systems Manager Parameter Store and AWS Secrets manager without having to declare a parameter
- Mappings - Optional section matches a key to a corresponding set of named values. Use the intrinsic function FindInMap to return the value corresponding to keys in a two-level map
- Outputs - Optional section that let you declare output values that you can import into other stacks (cross-stack references), return in response or view in the AWS Console
Basic Concepts
We automate to reduce effort, it is faster , reduce errors, increase consistency and ultimately costs
Exam Tips:
- Whenever possible, select an answer that doesn't include manual steps
- Make sure to select answers that gives you the chance to automate the entire process and not just a portion of it
-
System Manager
Features (not the full list):
- Automation Documents now called Runbooks enable you to configure the inside of your EC2 and AWS resources (e.g. bucket policy)
- Run Command it uses the System Manager Agent to do things in your EC2 instance such as running commands
- Patch Manager allows to select and deploy operating system and software patches automatically
- Parameter Store securely store your secrets and variable values, things you do not hard-code in your automation
- Hybrid Activations supports for both EC2 and your on-premise servers
- Session Manager remotely connect and interact with your EC2 instances
Exam Tips:
- System Manager will rarely be called out by name. Instead, the names of the features will be used
- On-Premise Support needs System Manager Agent installed on OS
- Overview is enough remember it can patch, update and configure instances should be good enough
- Unpaid SysAdmin if an admin can do it, Systems Manager can as well
- Runbooks / Automation Documents are usable by AWS Config
System Manager is a suite of tools designed to automate the management of EC2 instances and on-premise server. It is free for AWS resources while there is a fee for on-premise