Domain's Robot Army

14
Domain’s Robot Army CloudFormation, Windows and Octopus. Jason Brown, DevOps Lead, Domain.com.au Sydney AWS Meetup, October 2014

description

A talk delivered at the Oct 1st Sydney AWS Meetup, on how Domain uses CloudFormation, DSC and Octopus Deploy to support our microservices arcitecture with continuous delivery

Transcript of Domain's Robot Army

Page 1: Domain's Robot Army

Domain’s Robot ArmyCloudFormation, Windows and Octopus.

Jason Brown, DevOps Lead, Domain.com.auSydney AWS Meetup, October 2014

Jason Brown
Yeah, thought about that this week. At least I have the new homepage on the next slide!
Lyndon Maher
kinda late change, but you have the old logo :)
Page 2: Domain's Robot Army

Who Are We?

Page 3: Domain's Robot Army

What we’ll cover

The ChallengesThe CloudFormationThe Supporting CodeThe Gotchas

Page 4: Domain's Robot Army

Challenges at Domain● Complete Microservice re-architecture● Continuous Delivery● Agile ● Windows

Plus all the usual...

Page 5: Domain's Robot Army

How we do it

Page 6: Domain's Robot Army

Intro to CloudFormation● Infrastructure as code● Glue your AWS services together● Constantly expanding● Well documented● Lots of samples available● JSON syntax

Page 7: Domain's Robot Army

An example...

ELB

Health-check

HTTP port

HTTPS port

Cross-Zone

Tags!!

Page 8: Domain's Robot Army

CloudFormation at DomainWe took a pre-existing template and extended it

Then we cut it back down significantlyMulti-AZ Load-balanced, AutoScaling & Self-healingEach platoon has its own template and configCustomised LaunchConfigurationUses standard AWS AMIs Versioned using Git

Page 9: Domain's Robot Army

The LaunchConfiguration● The pivotal step● Lots of PowerShell● Pulls pre-built scripts from S3

based on cluster name

Page 10: Domain's Robot Army

The Powershell● Rename server● Set TZ● Pull files● cluster-config.json● Army config (DSC)● Platoon config (DSC)● Find latest app code● Notify

Page 11: Domain's Robot Army

Octopus DeployThe very last PowerShell Script drives OctopusDeploy.NET-based, API-first deployment enginePulls code from Bamboo/NugetPushes it out to serversExecutes supporting powershell code

Page 12: Domain's Robot Army

Gotchas- CFN-Init does not load windows profiles

- So it can’t use DPAPI or user environment variables

- More services means more stacks- We have to parameterise, or maintain lots of templates

- Multi-tenancy is tricky- Luckily, we want the resiliency of separate clusters

- OctopusDSC- We needed to customise OctopusDSC for AWS

- Octopus Reg/Dereg- Custom script to clean-up scaled-down instances

Page 13: Domain's Robot Army

In ConclusionYou can drive the entire provisioning chain - (yes, including app deployment)New cluster ~10-15 min Auto-scale: <10 minCloudformation is epicDomain’s new Microservices deploy on-commit, with the capacity to deploy hundreds of times per day to AWS.

Page 14: Domain's Robot Army

Want to learn more?

Follow Domain’s tech bloghttp://tech.domain.com.au/

And we are hiring!

Big thanks to all the Invader Zim fan sites which contributed images for this presentation!

Lyndon Maher
we are hiring. job ads are posted on the tech blog :)