Skip to content

Instantly share code, notes, and snippets.

View fangamb's full-sized avatar

fangamb

View GitHub Profile
@fangamb
fangamb / default.rb
Created August 9, 2012 09:42 — forked from emachnic/default.rb
Chef recipe to write redis.yml on Engine Yard Cloud
# ey-cloud-recipes/cookbooks/redis-yml/recipes/default.rb
if ['app_master', 'app'].include?(node[:instance_role])
redis_instance = node['utility_instances'].find { |instance| instance['name'] == 'redis' }
if redis_instance
node[:applications].each do |app, data|
template "/data/#{app}/shared/config/redis.yml"do
source 'redis.yml.erb'
owner node[:owner_name]
#Facebooker Post Authorize / Post DeAuthorize Callbacks
#from the FanGamb team - http://www.fangamb.com
class CallbacksController < ApplicationController
skip_before_filter :ensure_app_installed, :except => :post_authorize
skip_before_filter :verify_authenticity_token
def post_authorize
if request.post?
if verify_uninstall_signature
#set user's has_app indicator to 1 to indicate active