Skip to content

Instantly share code, notes, and snippets.

@toshihirock
Last active August 29, 2015 14:17
Show Gist options
  • Save toshihirock/89c100b753caa8245dca to your computer and use it in GitHub Desktop.
Save toshihirock/89c100b753caa8245dca to your computer and use it in GitHub Desktop.
{
"AWSTemplateFormatVersion" : "2010-09-09",
"Description" : "A simple stack that launches an instance.",
"Parameters" : {
"InstanceTypeParameter" : {
"Type" : "String",
"Default" : "t2.micro"
},
"KeyNameParameter" : {
"Type" : "String"
}
},
"Resources" : {
"Ec2Instance" : {
"Type" : "AWS::EC2::Instance",
"Properties" : {
"ImageId" : "ami-18869819",
"InstanceType" : { "Ref" : "InstanceTypeParameter" },
"KeyName" : { "Ref" : "KeyNameParameter" },
"SecurityGroupIds" : [ "sg-0da20468" ],
"Tags" : [ {"Key": "foo", "Value": "bar"} ]
}
}
},
"Outputs" : {
"InstanceId" : {
"Value" : { "Ref" : "Ec2Instance" }
},
"AvailabilityZone" : {
"Value" : { "Fn::GetAtt" : [ "Ec2Instance", "AvailabilityZone" ]}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment