Skip to content

Instantly share code, notes, and snippets.

{
"Resources": {
"AWSEBAutoScalingGroup": {
"Type": "AWS::AutoScaling::AutoScalingGroup",
"Properties": {
"HealthCheckType": "ELB",
"HealthCheckGracePeriod": 600
}
}
}
@rhysgodfrey
rhysgodfrey / aws-quick-start-demo-vpc-setup.template
Created October 19, 2014 15:25
AWS Quick Start Demo - VPC Setup
{
"AWSTemplateFormatVersion" : "2010-09-09",
"Description" : "AWS Quick Start Demo - VPC, Security Group, S3 Bucket and IAM role setup.",
"Parameters" : {
},
"Resources" : {
@rhysgodfrey
rhysgodfrey / aws-quick-start-demo-elasticbeanstalk-setup.template
Last active December 21, 2016 15:44
AWS Quick Start Demo - Elastic Beanstalk Setup
{
"AWSTemplateFormatVersion" : "2010-09-09",
"Description" : "AWS Quick Start Demo - Elastic Beanstalk App Setup.",
"Parameters" : {
"VPC": {
"Description" : "ID of the VPC to use",
"Type": "String",
"MinLength": "1",
@rhysgodfrey
rhysgodfrey / aws-quick-start-demo-create-beanstalk.ps1
Last active August 29, 2015 14:07
AWS Quick Start Demo - Elastic Beanstalk Setup Powershell
## https://gist.github.com/rhysgodfrey/b28ac3883bb78dd4f6f6 should be saved in the same directory as this script
## Values should be taken from the Cloud formation output variables after running aws-quick-start-demo-create-vpc-and-resources.ps1
$securityGroup = "sg-XYZ123";
$role = "ROLE-NAME";
$subnets = "subnet-XYZ123,subnet-XYZ456,subnet-XYZ789";
$vpc = "vpc-XYZ123";
## Value should be the name of an EC2 Key Pair you have access to
$key = "KEY-NAME";
@rhysgodfrey
rhysgodfrey / aws-quick-start-demo-create-vpc-and-resources.ps1
Created October 19, 2014 16:13
AWS Quick Start Demo - VPC and Resources Setup Powershell
## https://gist.github.com/rhysgodfrey/39ec61b1f3274bd43d5a should be saved in the same directory as this script as
$template = Get-Content .\aws-quick-start-demo-vpc-setup.template -Raw
New-CFNStack -StackName "AWSQuickStartDemo" -Capabilities @( "CAPABILITY_IAM" ) -TemplateBody $template
Set-AWSCredentials -AccessKey ACCESS-KEY -SecretKey SECRET-KEY -StoreAs AWSQuickStartDemo
Initialize-AWSDefaults -ProfileName AWSQuickStartDemo -Region eu-west-1
@rhysgodfrey
rhysgodfrey / aws-quick-start-demo-code-snippets.txt
Created November 9, 2014 16:28
Code Snippets for the AWS Quick Start Demo
#################
## BEFORE DEMO ##
#################
Set-AWSCredentials -AccessKey ACCESS-KEY -SecretKey SECRET-KEY -StoreAs AWSQuickStartDemo
Initialize-AWSDefaults -ProfileName AWSQuickStartDemo -Region eu-west-1
# Script at: https://gist.github.com/rhysgodfrey/518b61873fd449406cc0
.\create-vpc-and-resources.ps1
# Your account access key - must have read access to your S3 Bucket
$accessKey = "YOUR-ACCESS-KEY"
# Your account secret access key
$secretKey = "YOUR-SECRET-KEY"
# The region associated with your bucket e.g. eu-west-1, us-east-1 etc. (see http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html#concepts-regions)
$region = "eu-west-1"
# The name of your S3 Bucket
$bucket = "my-test-bucket"
# The folder in your bucket to copy, including trailing slash. Leave blank to copy the entire bucket
$keyPrefix = "my-folder/"
@rhysgodfrey
rhysgodfrey / README.md
Last active August 29, 2015 14:11
Allow HTTP Compression for Web Font Files

Allow HTTP Compression for Web Font Files - IIS

The following change will apply to all websites on the server, and requires an IIS Restart.

  1. Open C:\Windows\System32\inetsrv\config\applicationHost.config using notepad
  2. Find the <httpCompression ...> section
  3. Add the entries below above <add mimeType="*/*" enabled="false" /> in the <staticTypes> section
  4. Save the file
  5. Restart IIS (run iisreset from the command line)
{
"AWSTemplateFormatVersion" : "2010-09-09",
"Description" : "Test template for creating a beanstalk environment",
"Parameters" : {
"VPC": {
"Description" : "The AWS VPC to use.",
"Type": "AWS::EC2::VPC::Id"
},
"SubnetA": {
"Description" : "The Subnet in AZ A.",