Skip to content

Instantly share code, notes, and snippets.

View filiptepper's full-sized avatar
🏠
Working from home

Filip Tepper filiptepper

🏠
Working from home
View GitHub Profile
zstyle ":completion:*" use-cache on
zstyle ":completion:*" cache-path ~/.zsh/cache
rails_env = ENV['RAILS_ENV'] || "production"
rails_root = ENV['RAILS_ROOT'] || "/var/www/yourapp/current"
num_workers = 1
num_workers.times do |num|
God.watch do |w|
w.name = "resque-#{num}"
w.group = 'resque'
w.interval = 30.seconds
w.start = "cd #{rails_root} && env QUEUE=* RAILS_ENV=#{rails_env} /usr/bin/rake -f #{rails_root}/Rakefile environment resque:work"
module Punycode
module Status
class Error < StandardError; end
class PunycodeSuccess; end
# Input is invalid.
class PunycodeBadInput < Error; end
# Output would exceed the space provided.
class PunycodeBigOutput< Error; end
# Input needs wider integers to process.
class PunycodeOverflow < Error; end
require "erb"
require "redis"
module Rack
class Out
DEFAULTS = { :secret => "secretive-secret", :key => "rack:out",
:host => "127.0.0.1", :port => 6379, :db => 0, :timeout => 5, :password => nil,
:logger => nil, :thread_safe => nil }
def initialize(app, options = {})
sudo gem uninstall memcached
sudo env ARCHFLAGS="-arch x86_64" gem install memcached