This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| aws cloudformation wait stack-update-complete --stack-name=app |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| for i in $(seq 1 20); do | |
| aws cloudformation list-change-sets --stack-name app | grep CREATE_COMPLETE && if [ $? == 0 ]; then break; else continue; fi | |
| done; | |
| aws cloudformation execute-change-set \ | |
| --stack-name app \ | |
| --change-set-name app-$DOCKBIT_DEPLOYMENT_SHA |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| aws cloudformation create-change-set \ | |
| --stack-name app \ | |
| --change-set-name app-$DOCKBIT_DEPLOYMENT_SHA \ | |
| --template-body file://./AutoScalingRollingUpdates.json \ | |
| --parameters \ | |
| ParameterKey=KeyName,UsePreviousValue=true \ | |
| ParameterKey=SHAVersion,ParameterValue=$DOCKBIT_DEPLOYMENT_SHA |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sensu_snippet "hipchat" do | |
| content(:apikey => node["monitor"]["hipchat_api_key"], :room => node["monitor"]["hipchat_room"]) | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {"timestamp":"2013-05-29T17:03:34.486166+0200","level":"info","message":"GET /events","remote_address":"xx.xx.xx.xx","user_agent":"EventMachine HttpClient","request_method":"GET","request_uri":"/events","request_body":""} | |
| {"timestamp":"2013-05-29T17:03:34.486841+0200","level":"info","message":"GET /checks","remote_address":"xx.xx.xx.xx","user_agent":"EventMachine HttpClient","request_method":"GET","request_uri":"/checks","request_body":""} | |
| {"timestamp":"2013-05-29T17:03:34.487364+0200","level":"info","message":"GET /clients","remote_address":"xx.xx.xx.xx","user_agent":"EventMachine HttpClient","request_method":"GET","request_uri":"/clients","request_body":""} | |
| {"timestamp":"2013-05-29T17:03:34.487752+0200","level":"info","message":"GET /stashes","remote_address":"xx.xx.xx.xx","user_agent":"EventMachine HttpClient","request_method":"GET","request_uri":"/stashes","request_body":""} | |
| {"timestamp":"2013-05-29T17:03:34.488324+0200","level":"info","message":"GET /info","remote_address":"xx.xx.xx.xx","user_agent":"Eve |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| # | |
| # Parse the output of lnstat(8) into something perhaps slightly | |
| # human-readable. | |
| # | |
| # Can take input from a file or on stdin. | |
| import sys | |
| lnstat_output = open(sys.argv[1]) if len(sys.argv) >= 2 else sys.stdin |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [ahmedelgamil@VBook chef-repo]$ knife node list | |
| chef-server | |
| precise-cookbook-test | |
| [ahmedelgamil@VBook chef-repo]$ knife search node name:chef-server | |
| 1 items found | |
| Node Name: chef-server | |
| Environment: _default | |
| FQDN: ip-*-*-*-*.us-west-2.compute.internal | |
| IP: *.*.*.* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ sudo ruby script/rails server | |
| => Booting WEBrick | |
| => Rails 3.1.3 application starting in development on http://0.0.0.0:3000 | |
| => Call with -d to detach | |
| => Ctrl-C to shutdown server | |
| Exiting | |
| /var/lib/gems/1.8/gems/activesupport-3.1.3/lib/active_support/whiny_nil.rb:48:in `method_missing': undefined method `values' for nil:NilClass (NoMethodError) | |
| from /var/lib/gems/1.8/gems/mongoid-2.4.5/lib/mongoid/railtie.rb:83 | |
| from /var/lib/gems/1.8/gems/railties-3.1.3/lib/rails/initializable.rb:30:in `instance_exec' | |
| from /var/lib/gems/1.8/gems/railties-3.1.3/lib/rails/initializable.rb:30:in `run' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [2012-07-04T00:13:01+02:00] INFO: *** Chef 10.12.0 *** | |
| [2012-07-04T00:13:05+02:00] INFO: Run List is [role[sensu], role[sensu_api], role[sensu_client], role[sensu_dashboard], role[sensu_server], recipe[sensu::redis]] | |
| [2012-07-04T00:13:05+02:00] INFO: Run List expands to [sensu::api, sensu::client, sensu::dashboard, sensu::server, sensu::redis] | |
| [2012-07-04T00:13:05+02:00] INFO: Starting Chef Run for chef-server | |
| [2012-07-04T00:13:05+02:00] INFO: Running start handlers | |
| [2012-07-04T00:13:05+02:00] INFO: Start handlers complete. | |
| [2012-07-04T00:13:05+02:00] INFO: Loading cookbooks [apt, build-essential, erlang, iptables, rabbitmq, redis, runit, sensu, yum] | |
| [2012-07-04T00:13:06+02:00] INFO: Processing execute[apt-get-update] action run (apt::default line 22) | |
| [2012-07-04T00:13:06+02:00] INFO: Processing execute[apt-get update] action nothing (apt::default line 29) | |
| [2012-07-04T00:13:06+02:00] INFO: Processing package[update-notifier-common] action install (apt::default line 36) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module Deployinator | |
| module Stacks | |
| module Webtier | |
| ### Production environment methods | |
| ## current version deployed in production | |
| def webtier_prod_version | |
| # %x{curl http://my-app.com/version.txt} | |
| "1.1" |