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
check process unicorn | |
with pidfile /var/www/RescueRails_staging/current/tmp/pids/unicorn.pid | |
start program = "/etc/init.d/unicorn_RescueRails_staging start" | |
as uid deploy and gid deploy | |
stop program = "/etc/init.d/unicorn_RescueRails_staging stop" | |
as uid deploy and gid deploy | |
if mem is greater than 300.0 MB for 1 cycles then restart # eating up memory? | |
if cpu is greater than 50% for 2 cycles then alert # send an email to admin | |
if cpu is greater than 80% for 30 cycles then restart # hung process? | |
group unicorn |
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
add_column :users, :has_own_cats | |
#Our radio button to fill out the answer in new or edit views | |
<div class="control-group"> | |
<%= f.label :has_own_cats, "Do you have your own cats?", :class => "control-label" %> | |
<div class="controls"> | |
<label> |
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 has been generated from unicorn_template.rb.erb which is greatly inspired from: | |
# https://github.com/ricodigo/ricodigo-capistrano-recipes/blob/master/generators/unicorn.rb.erb | |
# | |
# See http://unicorn.bogomips.org/Unicorn/Configurator.html for complete | |
# documentation. | |
# Local variables | |
old_pid = '/var/www/rescuerails/shared/pids/unicorn.pid.old' | |
# Unicorn setup |
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
#!/bin/sh | |
### BEGIN INIT INFO | |
# Provides: nginx | |
# Required-Start: $network $remote_fs $local_fs | |
# Required-Stop: $network $remote_fs $local_fs | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Stop/start nginx | |
### END INIT INFO |
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 has been generated from unicorn_template.rb.erb which is greatly inspired from: | |
# https://github.com/ricodigo/ricodigo-capistrano-recipes/blob/master/generators/unicorn.rb.erb | |
# | |
# See http://unicorn.bogomips.org/Unicorn/Configurator.html for complete | |
# documentation. | |
# Local variables | |
old_pid = '<%= unicorn_pid + ".old" %>' | |
# Unicorn setup |