i5m
October 27th, 2006, 11:06 AM
I'd usually happliy plug away trying to get things working, but I don't have a lot of a free time at the moment so I was wondering if anyone else had got snaps (http://fadingred.org/trac/snaps)up and running on their OCS account and if so could they pass on some instructions?
I think it is this bit that is screwing me:
Make sure that if the base of the rails install is not at the root of the URL, that either the webserver rewrites the base (strips whatever needs to be stripped to fool rails) or that rails is aware of this change using that funky config.
I've installed snaps at: /home/username/rails_sites/snaps
My lighttpd.conf has:
server.document-root = "/home/username/public_html/"
fastcgi.server = (
".fcgi" =>
( "localhost" =>
(
"socket" => "/home/username/lighttpd-fcgi-username.socket",
"bin-path" => "/home/username/rails_sites/snaps/public/dispatch.fcgi",
"bin-environment" => ( "RAILS_ENV" => "production" ),
"min-procs" => 1,
"max-procs" => 1,
"idle-timeout" => 60,
"allow-x-send-file" => "enable"
)
),
I use lighttpd for the whole domain.
If I restart lighttpd I get the following:
/usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:459:in `read': No such file or directory - /home/username/rails_sites/snaps/public/../config/../config/database.yml (Errno::ENOENT)
from /usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:459:in `database_configuration'
from /usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:181:in `initialize_database'
from /usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:84:in `process'
from /usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:42:in `run'
from /home/username/rails_sites/snaps/public/../config/environment.rb:10
from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
from /home/username/rails_sites/snaps/public/dispatch.fcgi:21
From the looks of it it's a simple file path problem:
No such file or directory - /home/username/rails_sites/snaps/public/../config/../config/database.yml (Errno::ENOENT)
Cheers for any help you can provide.
I think it is this bit that is screwing me:
Make sure that if the base of the rails install is not at the root of the URL, that either the webserver rewrites the base (strips whatever needs to be stripped to fool rails) or that rails is aware of this change using that funky config.
I've installed snaps at: /home/username/rails_sites/snaps
My lighttpd.conf has:
server.document-root = "/home/username/public_html/"
fastcgi.server = (
".fcgi" =>
( "localhost" =>
(
"socket" => "/home/username/lighttpd-fcgi-username.socket",
"bin-path" => "/home/username/rails_sites/snaps/public/dispatch.fcgi",
"bin-environment" => ( "RAILS_ENV" => "production" ),
"min-procs" => 1,
"max-procs" => 1,
"idle-timeout" => 60,
"allow-x-send-file" => "enable"
)
),
I use lighttpd for the whole domain.
If I restart lighttpd I get the following:
/usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:459:in `read': No such file or directory - /home/username/rails_sites/snaps/public/../config/../config/database.yml (Errno::ENOENT)
from /usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:459:in `database_configuration'
from /usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:181:in `initialize_database'
from /usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:84:in `process'
from /usr/lib/ruby/gems/1.8/gems/rails-1.1.6/lib/initializer.rb:42:in `run'
from /home/username/rails_sites/snaps/public/../config/environment.rb:10
from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
from /home/username/rails_sites/snaps/public/dispatch.fcgi:21
From the looks of it it's a simple file path problem:
No such file or directory - /home/username/rails_sites/snaps/public/../config/../config/database.yml (Errno::ENOENT)
Cheers for any help you can provide.