On Wed, Apr 20, 2011 at 2:55 AM, Frederick Cheung < [email protected]> wrote:
> > On 19 Apr 2011, at 11:30, johnnybutler7 <[email protected]> wrote: > > > Aha thanks, i knew it would be something silly. The docs do suggest > > adding the gemfile.lock > > to your repository but based on this evidence thats not a good idea. > > I will need to find out how to > > manage this when deploying, do you add the production gemfile.lock to > > the repo........ > > > I've never had to do this (and I seen to have many of the test gems you do > (rspec , cucumber etc) > > Fred > I suspected that your Gemfile.lock was set to the dev/test environment on your system and therefore was not set for the staging environment that you wanted it to be. Even though you said to run it in staging, Rails saw a Gemlock.file and checked that before executing the Gemfile. B. > > On Apr 18, 2:50 pm, Bryan Crossland <[email protected]> wrote: > >> On Mon, Apr 18, 2011 at 5:43 AM, johnnybutler7 <[email protected] > >wrote: > >> > >>> Yes i did bundle install --without test and that worked fine, when i > >>> try the db migrate for staging > >>> i get the error, i could install all the gems as you say rspec is > >>> needed for other stuff possibly but > >>> the actual error for the autotest gem is because its specific to mac, > >>> the staging site is on linux. From reading > >>> the docs it seems to suggest that bundler will know what OS you are on > >>> and install the appropriate gem. The whole point of > >>> the grouping should be exactly for this reason, i shouldnt have to > >>> install test/dev gems on the staging/production server. > >> > >>> Maybe its something silly im doing but but i can see what..... > >> > >> You didn't happen to move over your Gemfile.lock from your mac to your > >> staging server did you? If you did, try deleting that file and running > the > >> command again. > >> > >> B. > >> > >> > >> > >>> On Apr 18, 11:16 am, Frederick Cheung <[email protected]> > >>> wrote: > >>>> On Apr 15, 2:01 pm, johnnybutler7 <[email protected]> wrote: > >> > >>>>> Hi, > >> > >>>>> I have gem file set up so only the specific gems are installed/needed > >>>>> for each environment, so all the test gems like cucumber etc are > >>>>> grou[ed in test. When i try a rake db:migrate RAILS_ENV=staging on > >>>>> the staging server however i get an error saying XXXX gem is not > >>>>> installed, please use bundle install. I dont want the test gems > >>>>> installed on this server however when i run the migration on staging > >>>>> its expecting them to be installed. > >> > >>>>> Anyone hit this problem before and how did you sort it, i cant find > >>>>> anything in the forums? > >> > >>>> did you run bundle install --without test --without development > >> > >>>> Some gems (like rspec) used to generate rake files that required rspec > >>>> to be loaded, so when rails tried to load your rake tasks it would > >>>> fail if those gems weren't there anymore. They don't anymore though, > >>>> now that everyone has figured out the sensible ways of working with > >>>> bundler - I'd try using a current versions of those gems and clearing > >>>> out any unneeded rake task files. > >> > >>>> Fred > >> > >>>>> JB > >> > >>> -- > >>> You received this message because you are subscribed to the Google > Groups > >>> "Ruby on Rails: Talk" group. > >>> To post to this group, send email to [email protected] > . > >>> To unsubscribe from this group, send email to > >>> [email protected]. > >>> For more options, visit this group at > >>> http://groups.google.com/group/rubyonrails-talk?hl=en. > > > > -- > > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > > To post to this group, send email to [email protected]. > > To unsubscribe from this group, send email to > [email protected]. > > For more options, visit this group at > http://groups.google.com/group/rubyonrails-talk?hl=en. > > > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/rubyonrails-talk?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

