Maybe I'm missing something obvious, but can't you specify a group for
those gems and then only deploy them in dev and test?  So as part of
your deployment to heroku you'd do something like: bundle install --
without gems_heroku_dun_like

I'm going to have to deal with exactly the same problem so I'm curious
if this will work for you.

Gabriel

On Aug 31, 11:32 am, Ashley Moran <ashley.mo...@patchspace.co.uk>
wrote:
> On 30 Aug 2010, at 23:54, Terence Lee wrote:
>
> > In the near future we're going to start requiring the Gemfile.lock to be
> > checked into your git repository since this is the recommended deploy
> > path set by the bundler team.  Please take the time to do so if you
> > haven't already.
>
> There's an unfortunate downside to this.  Our Gemfile has gems that can't be 
> built on Heroku (autotest-fsevent, for example).  We avoided deployment 
> issues by altering the Gemfile to only bundle these on OS X:
>
>     if RUBY_PLATFORM =~ /darwin/
>       gem "autotest-fsevent"
>       # ...
>     end
>
> Then, we deliberately left the lock file out of Git so that Heroku would 
> bundle correctly without these gems while compiling the slug.
>
> Today we tried to update our deployment scripts to keep the lockfile in Git.  
> This now means we have to have a Rake task to set an environment variable 
> ENV["HEROKU"], re-bundle with a Gemfile that now looks like this...
>
>   unless ENV["HEROKU"]
>     gem "autotest-fsevent"
>     # ...
>   end
>
> ...then commit the lockfile to Git, and finally push to Heroku.
>
> We have other issues that I think we can resolve.  But the above feels like a 
> lot of hoop-jumping to get a lockfile on Heroku.
>
> I'd love to know if anyone has a solution to this problem.  Last time I asked 
> nobody had a simple workaround.  But that was April, I think, and Bundler and 
> Heroku have both changes since then.
>
> Or, are we alone in having OSX-specific gems in our Gemfile?
>
> Advice much appreciated
>
> Cheers
> Ash
>
> --http://www.patchspace.co.uk/http://www.linkedin.com/in/ashleymoran

-- 
You received this message because you are subscribed to the Google Groups 
"Heroku" group.
To post to this group, send email to her...@googlegroups.com.
To unsubscribe from this group, send email to 
heroku+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/heroku?hl=en.

Reply via email to