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 will ride alongside god and kill any rogue memory-greedy | |
# processes. Their sacrifice is for the greater good. | |
unicorn_worker_memory_limit = 300_000 | |
Thread.new do | |
loop do | |
begin | |
# unicorn workers | |
# |
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
require 'spec_helper' | |
describe Album do | |
before(:all) do | |
@album = Factory.build(:album) | |
@website = @album.website | |
end | |
it "should be valid" do | |
@album.should be_valid | |
end |
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/bash | |
### BEGIN INIT INFO | |
# Provides: god | |
# Required-Start: $all | |
# Required-Stop: $network $local_fs $syslog | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Start the god monitoring processes | |
# Description: Enable god at boot time. | |
### 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
# http://unicorn.bogomips.org/SIGNALS.html | |
# change these to match your app | |
app_name = "APP_NAME" | |
rvm_string = "RVM_STRING" | |
user = "USER" | |
pid_file = "/srv/webapps/#{app_name}/shared/pids/#{app_name}.pid" | |
gem_home = "/usr/local/rvm/gems/#{rvm_string}" | |
app_root = "/srv/webapps/#{app_name}/current" |
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/bash | |
### BEGIN INIT INFO | |
# Provides: APPLICATION | |
# Required-Start: $all | |
# Required-Stop: $network $local_fs $syslog | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Start the APPLICATION unicorns at boot | |
# Description: Enable APPLICATION at boot time. | |
### 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
/* | |
Jquery and Rails powered default application.js | |
Easy Ajax replacement for remote_functions and ajax_form based on class name | |
All actions will reply to the .js format | |
Unostrusive, will only works if Javascript enabled, if not, respond to an HTML as a normal link | |
respond_to do |format| | |
format.html | |
format.js {render :layout => false} | |
end | |
*/ |