Skip to content

Instantly share code, notes, and snippets.

@kdonovan
Created June 17, 2011 01:04
Show Gist options
  • Save kdonovan/1030667 to your computer and use it in GitHub Desktop.
Save kdonovan/1030667 to your computer and use it in GitHub Desktop.
Contents of the file apn_sender's generator puts in script/apn_sender (for those on Rails 3, where the generator isn't working yet)
#!/usr/bin/env ruby
# Daemons sets pwd to /, so we have to explicitly set RAILS_ROOT
RAILS_ROOT = File.expand_path(File.join(File.dirname(__FILE__), '..'))
require 'rubygems'
require 'apn'
require 'apn/sender_daemon'
APN::SenderDaemon.new(ARGV).daemonize
@dysto93
Copy link

dysto93 commented Dec 21, 2012

what is the format for apn_sender ? apn_sender.rb ? or other ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment