Bugs: Browse | Submit New | Admin

[#21900] glean gems from Rails environment

2008-09-10 15:31
Submitted By:
Bill Burcham (bburcham)
Assigned To:
Paul Dowman (pdowman)
Capistrano tasks
glean gems from Rails environment

Detailed description
Eliminate redundant gem specification in deploy.rb and reuse the Rails 2.1 specs as described in this thread:


Add A Comment: Notepad

Please login


Date: 2009-02-05 00:53
Sender: Paul Dowman

This will probably be supported soon. But after using them I
now think the Rails gem rake tasks are broken. Here's why:

The main problem is that installing gems needs to be done as
root.  Therefore rake gems:install needs to be run as root. But
rake starts up the whole Rails environment, so now you have your
Rails environment starting up (probably for the first time) as
root. Some plugins (e.g. attachment_fu) initialize temporary
directories and other things on first startup, so these files/dirs
become owned by root and unwritable by the normal app user when
the app is started normally.

Also, since your rails initialization code is run when rake runs,
if it refers to a constant from one of the gems you're installing
it won't be available.

Hopefully the gems:install tasks will be reworked in Rails though,
because it's a good idea.
Date: 2008-09-23 16:46
Sender: Paul Dowman

Supporting the new gem rake tasks is definitely planned for some
point in the future, but removing the existing gem installation
tasks would mean removing support for old versions of Rails and
possibly Merb (I don't know if EC2 on Rails actuall works with
Merb, but I'd like it to).

Attached Files:

Name Description Download
No Files Currently Attached


No Changes Have Been Made to This Item