-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[NOSTORY] Add whacamole for restarting heroku dynos on production whe…
…n they hit memory limits.
- Loading branch information
1 parent
fa719d7
commit 18e4c6c
Showing
7 changed files
with
19 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
release: bundle exec rake heroku:release | ||
web: bundle exec puma -C config/puma.rb | ||
worker: bundle exec rake jobs:work | ||
whacamole: bundle exec whacamole -c ./config/whacamole.rb | ||
|
||
# comment: consider bin/rails server -p $PORT -e $RAILS_ENV for web (old heroku default) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Whacamole.configure("affinityworks") do |config| | ||
config.api_token = ENV['HEROKU_API_TOKEN'] | ||
config.dynos = %w{web} | ||
config.restart_threshold = 1000 # MB | ||
config.restart_window = 30*60 # SECONDS | ||
end | ||
|
||
Whacamole.configure("production-swingleft") do |config| | ||
config.api_token = ENV['HEROKU_API_TOKEN'] | ||
config.dynos = %w{web} | ||
config.restart_threshold = 500 # MB | ||
config.restart_window = 30*60 # SECONDS | ||
end |