public
Description: Merb More: The Full Stack. Take what you need; leave what you don't.
Homepage: http://www.merbivore.com
Clone URL: git://github.com/wycats/merb-more.git
fix up merb-fcgi binary to work out of the box
ezmobius (author)
Mon Mar 24 16:17:33 -0700 2008
commit  b5467e5138b8c18c0c521a5fce5ea529f1a090d6
tree    b201cfab820b88a522c79ded9239eba53625ee28
parent  3a13dac3bfdb4e37d20095e254f36437fcf0cc84
...
2
3
4
5
 
 
 
 
6
7
 
8
9
 
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
 
 
 
 
 
25
...
2
3
4
 
5
6
7
8
9
 
10
11
 
12
13
14
15
 
16
 
17
 
 
 
 
 
 
 
18
19
20
21
22
23
24
0
@@ -2,22 +2,21 @@
0
                                                                
0
 require 'rubygems'
0
 require 'merb-core'
0
-
0
+
0
+# this is Merb.root, change this if you have some funky setup.
0
+merb_root = File.expand_path(File.dirname(__FILE__) / '../')
0
+
0
 # If the fcgi process runs as apache, make sure
0
-# we have an inlinedir set
0
+# we have an inlinedir set for Rubyinline action-args to work
0
 unless ENV["INLINEDIR"] || ENV["HOME"]
0
- tmpdir = File.dirname(__FILE__) + "/../tmp"
0
+ tmpdir = merb_root / "tmp"
0
   unless File.directory?(tmpdir)
0
     Dir.mkdir(tmpdir)
0
   end
0
-
0
   ENV["INLINEDIR"] = tmpdir
0
-
0
 end
0
-
0
-# the merb root should alwasy be located below
0
-# to set the root dir
0
-argv = ARGV + %w[-a fcgi -m ..]
0
-
0
-# start
0
-Merb.start(argv)
0
\ No newline at end of file
0
+
0
+# start merb with the fcgi adapter, add options or change the log dir here
0
+Merb.start(:adapter => 'fcgi',
0
+ :merb_root => merb_root,
0
+ :log_file => merb_root /'log'/'merb.log')
0
\ No newline at end of file

Comments

    No one has commented yet.