Hi David,

On Tue, Jun 09, 2009 at 09:29:22AM -0400, David Susco wrote:
I'd definitely be interested in seeing any work you do with this.
Having it up on the wiki would be nice too.

I'm still trying to figure out deployment with camping 1.5. I've
experimented with 1.9.316 and rack but have yet to get an app to work
with that. The same with Picnic.

Been meaning to write a quick overview of how I did it for you (as
documentation is super sparse still). Briefly:

(1) Read the passenger user guide at:
http://www.modrails.com/documentation/Users%20guide.html

I installed passenger from a gem but see the user's guide if you need
to install on debian using apt (it is in the Ubuntu repositories already).
Similarly rack is from a gem, and I use the same version of camping as
you (from Judofyr's gem server).

(2) Try and get the "hello world" from the passenger user guide to
work for you.

(3) Then try and get the blog example working that is shipped with
camping. Here is a config.ru that works for that:

require 'rubygems'
require 'rack'
require 'camping'
require 'blog'
Blog::Models::Base.establish_connection :adapter => "sqlite3",
:database => "/home/jonathan/.camping.db"
run Blog

Change the database path to one you have on your system. You may need
something like:
Blog::Models.create_schema :assume => (Blog::Models::Post.table_exists? ? 1.0 : 
0.0)

before "run blog" if your sqlite database doesn't yet have the schema
for the blog example.

(4) And the apache config that I used was something like:

<Directory />
              Options ExecCGI FollowSymLinks
                 AllowOverride all
                    Allow from all
</Directory>
<VirtualHost *:80>
    ServerName www.rackexample.com
    DocumentRoot /var/www/blog/public
</VirtualHost>

You may need to edit your hosts file so that www.rackexample.com
resolves to your apache server.

(5) Let us know how it goes...

Regards,
Jonathan
_______________________________________________
Camping-list mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/camping-list

Reply via email to