Orchestration is the automated arrangement, coordination, and management of complex computer systems, middleware and services.cit. Wikipedia
AWS CloudFormation gives developers and systems administrators an easy way to create and manage a collection of related AWS resources, provisioning and updating them in an orderly and predictable fashion.
Template
it is a JSON formatted file. It describes PARAMTERS, RESOURCES and ACTION
Stack
When you use AWS CloudFormation, you manage related resources as a single unit called a stack.
you can generate a change set, which is summary of your proposed changes.
versioning, update, delete fast
{
"Parameters" : {
"VPCName" : {
"Type" : "String",
"Default" : "staging",
"Description" : "VPC name"
}
},
"Resources" : {
"Staging": {
"Type" : "AWS::EC2::VPC",
"Properties" : {
"CidrBlock" : "10.15.0.0/16",
"EnableDnsSupport" : true,
"EnableDnsHostnames" : true,
"InstanceTenancy" : "default",
"Tags" : [{"Key": "Name", "Value": {"Ref": "VPCName"}}]
}
}
}
}
{
"Resources" : {
"Staging": {
"Type" : "AWS::EC2::VPC",
"Properties" : {
"CidrBlock" : "10.15.0.0/16",
"EnableDnsSupport" : true,
"EnableDnsHostnames" : true,
"InstanceTenancy" : "default",
"Tags" : [{"Key": "Name", "Value": {"Ref": "VPCName"}}]
}
},
"DatabaseSubnet1": {
"Type" : "AWS::EC2::Subnet",
"Properties" : {
"AvailabilityZone" : "eu-west-1a",
"CidrBlock" : "10.15.1.0/28",
"MapPublicIpOnLaunch" : true,
"VpcId": {"Ref" : "Staging"},
"Tags": [{"Key": "Name", "Value": "db-1a"}]
}
}
}
}
aws cloudformation create-stack
--stack-name devops_stage
--template-body file:///home/gianarb/devops.json
--parameters VPCName=staging,AppName=test