Deployment & Instance Management Flashcards
1
Q
Elastic Beanstalk Billing
A
Free itself, pay for underlying instances
2
Q
Elastic Beanstalk Managed Services
A
- Instance/OS configuration (EC2, Elastic IP, RDS master)
- Configurable deployment strategy
3
Q
Elastic Beanstalk Architecture Models
A
- Single Instance - Dev
- LB + ASG + Standby RDS - Prod/Staging, multi AZ
- SQS + ASG - Prod, non-web, workers etc
4
Q
Elastic Beanstalk Worker Setup
A
- Long to complete, decoupling app into two tiers
- Can be called from web-app tier through SQS
- Can define periodic tasks into cron.yaml
5
Q
Elastic Beanstalk Blue/Green
A
- Using Route53 weighted routing
- Swap urls (DNS swap), when test v2 is done
6
Q
OpsWorks
A
- Chef & Puppet based on-prem, helps migrate to cloud
- Linux/Windows
- Open source, cross-cloud
- Cannot manage ASG
7
Q
OpsWorks Layers
A
Stack contains Layers
- ELB (ex ALB)
- Application Server (EC2) needs cookbook and app repository access
- Database (RDS)
8
Q
AWS CodeDeploy
A
- Managed Service Using CodeDeploy Agent: - EC2 - ASG - ECS - Lambda
9
Q
AWS CodeDeploy EC2
A
- appspec.yml + deployment strategy
- in place updates
- hooks for verification after each deploy phase
- Example -> half n half
10
Q
AWS CodeDeploy Lambda
A
- Traffic shifting feature
- Pre and Post traffic hooks (lambda functions) to validate deployment (before traffic shift starts and after it ends)
- Easy & automated rollback using CW Alarms
- SAM framework natively uses CodeDeploy
11
Q
AWS CodeDeploy ECS
A
- Facilitates Blue/Green in ECS
- Setup is within ECS service definition
- Creates new task set, traffic shifting
- If stable for x minutes, old task set terminated
12
Q
CloudFormation (IaC) & ASG
A
- CF manages ASG only, not underlying EC2
- Can define “success conditions”, for launch of EC2 via CreationPolicy
- Can define “update strategies” for update of EC2 via UpdatePolicy
13
Q
CloudFormation - Retaining Data on Deletes
A
- Attach DeletePolicy to resource to control CF del action
- Retain - preserve/backup (works on nested stack)
- Snapshot
- Delete - default for most except (RDS DB cluster which is Snapshot)
- To delete S3 bucket, remove contents first
14
Q
CloudFormation and IAM
A
- Uses IAM principal permissions
- Or can assign IAM role to the stack
- To create IAM resources, need to explicitly provide capability to CF, CAPABILITY_IAM or CAPABILITY_NAMED_IAM
15
Q
CloudFormation Custom Resources using Lambda
A
- Not yet supported in CF new aws service
- Empty content of S3 bucket
- On-prem resource
- Fetch AMI id, etc…