Skip to content

Instantly share code, notes, and snippets.

@marano
Created April 7, 2016 17:06
Show Gist options
  • Save marano/0f963a67bc9f3059235d420e6351dda5 to your computer and use it in GitHub Desktop.
Save marano/0f963a67bc9f3059235d420e6351dda5 to your computer and use it in GitHub Desktop.
application: example_app
common:
solution_stack_name: 64bit Amazon Linux 2015.03 v1.3.1 running Ruby 2.1 (Passenger Standalone)
smoke_test: |
curl_http_code = "curl -s -o /dev/null -w \"%{http_code}\" http://#{host_name}"
Timeout.timeout(600) do
until ['200', '301', '302'].include?(`#{curl_http_code}`.strip)
sleep 5
end
end
option_settings:
- namespace: aws:autoscaling:launchconfiguration
option_name: InstanceType
value: m1.small
- namespace: aws:elasticbeanstalk:application:environment
option_name: DATABASE_NAME
value: example_app
- namespace: aws:elasticbeanstalk:application:environment
option_name: DATABASE_USERNAME
value: example_app
- namespace: aws:elasticbeanstalk:application:environment
option_name: DATABASE_PASSWORD
value: PleaseChangeMe
resources:
template: config/rds.json
inputs:
DBName: example_app
DBUser: example_app
DBPassword: PleaseChangeMe
outputs:
RDSPassSecurityGroup:
namespace: aws:autoscaling:launchconfiguration
option_name: SecurityGroups
RDSHost:
namespace: aws:elasticbeanstalk:application:environment
option_name: DATABASE_HOST
RDSPort:
namespace: aws:elasticbeanstalk:application:environment
option_name: DATABASE_PORT
environments:
dev:
strategy: inplace-update
production:
option_settings:
- namespace: aws:elasticbeanstalk:application:environment
option_name: SECRET_KEY_BASE
value: 52f6fb66e2e8306dff7e5a0964f46df25239e377ceab35ba29966c1292862a1e00ca2e09333527b10427902fe287
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment