I am trying to get an nginx/unicorn ruby app server configured with chef. The problem I am running into is a dependency on the build-essential cookbook which when run, results in the output:
================================================================================
Error executing action `install` on resource 'package[build-essential]'
================================================================================
Chef::Exceptions::Exec
----------------------
apt-get -q -y install build-essential=11.5ubuntu2 returned 100, expected 0
I am still pretty new to chef and am not sure why this is happening. Any ideas?
As soon as I posted this it occurred to me that maybe apt wasn’t updating first. Sure enough, I needed to have the apt cookbook installed and in the run list ahead of nginx. This solves the problem.