GitHub Sale: sign up for any paid plan this week and pay nothing until January 1, 2009!  [ hide ]

public
Description: A simple application written in merb to help you manage ad serving across multiple sites
Clone URL: git://github.com/kneath/greed.git
kneath (author)
Tue Apr 22 16:46:01 -0700 2008
commit  bf6bd400f7391f0af67b5f4a4146b4d6aac48731
tree    0eb364d3aa87211bac88aa439d614d82cba0892a
greed / public / merb.fcgi
100644 22 lines (18 sloc) 0.742 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/usr/bin/env ruby
                                                               
require 'rubygems'
require 'merb-core'
 
# this is Merb.root, change this if you have some funky setup.
merb_root = File.expand_path(File.dirname(__FILE__) / '../')
        
# If the fcgi process runs as apache, make sure
# we have an inlinedir set for Rubyinline action-args to work
unless ENV["INLINEDIR"] || ENV["HOME"]
  tmpdir = merb_root / "tmp"
  unless File.directory?(tmpdir)
    Dir.mkdir(tmpdir)
  end
  ENV["INLINEDIR"] = tmpdir
end
   
# start merb with the fcgi adapter, add options or change the log dir here
Merb.start(:adapter => 'fcgi',
           :merb_root => merb_root,
           :log_file => merb_root /'log'/'merb.log')