-
Provision
-
Create the
templates/parent.config.yml
, by making copy ofparent.example.config.yml
and setting the existingVpcID
,SubnetId
(at least two subntes)awless list subnets
-
Create "users" stack, which will create AWS user and credentials for Travis CI
make users
-
Create "parent" stack, which will create ALB, ECS Cluster and ASG, etc
make parent
-
Build Docker image and create "app" stack, which will create ECS Service, Target Group, ALB Listener, etc
make archersaurus
-
Set the rollback trigger for "app" stack (this command is not aviliable in the latest (0.1.9) awless yet and require custom build from my fork)
make set_rollback_trigger
-
Deploy ecs-drain-lambda for instance drain automation
-
-
ECS AMI Update process
-
Get lastet ECS AMI Id. Example
-
Update the AMI IDs map in the
templates/parent.yml
-
Update parent stack
make parent_update
-
Watch the ECS instance being drained in the UI on the ECS page and in the CloudWatch logs of deployed
ecs-drain-lambda
-
-
Deploying the app with TravisCI
-
Fork this repository and configure TravisCI build
-
Get the name of created ECR repository
make repos
and copy ECR repo url from output
-
Get AWS User credentials from create "users" stack
make show_users_stack
and copy the credentials from output
-
Configure Travis CI, by setting secret env variables for the project
-
AWS_REGION
-
AWS_ACCESS_KEY_ID
-
AWS_SECRET_ACCESS_KEY
-
ECR_REPO
-
-
Push some changes and see that Travis Picked up the build, see the build progress
-
-
Verifying rollback logic
- In the
templates/archersaurus.yml
uncomment the# Command: ["crash"]
line and push changes
- In the
-
Notifications
You must be signed in to change notification settings - Fork 2
taraspos/ecs-cloudformation-demo
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published