Not working on Ubuntu 14.04

With the new LTS release of ubuntu, the rubygems package was removed.

A quick fix would be:

    if $::osfamily == 'Debian' and $::operatingsystemrelease == '12.04' {
      $deps = ['gcc','rubygems', 'libssl-dev', 'ruby-dev']
    }
    else {
      $deps = ['gcc','libssl-dev', 'ruby-dev']
    }
yes.

Because in order to install the gem the packages need to be installed.

ensure_packages just makes sure that this will happen without breaking the package definition in other manifests.

The manifest is not necessarily executed from top to bottom.