DanThiffault / rails-lastmile

Chef rails configuration
MIT License
28 stars 23 forks source link

100% CPU After Provisioning #15

Closed jherdman closed 11 years ago

jherdman commented 11 years ago

I noticed that I'm hitting 100% CPU after provisioning. It seems that the newly provisioned machine kicks up Unicorn which then proceeds to spawn workers, which then immediately crash as the database is not found.

I think the cause is rooted in how this recipe is invoked. As of writing, the interesting bit of code is in "recipes/default.rb" lines 50-69. The non-reset condition is not idempotent, it should attempt to create the database and then migrate it.