Add logic to handle older versions of nginx cookbook

In order to allow this cookbook to be compatible with versions of the
nginx cookbook prior to 2.0.0 and after, this commit adds logic to check
the version and include the http_realip_module correctly for that
version of the nginx cookbook.

[24882]
Switch to ternary for nginx cookbook logic

In order to simplify the code used to set the http_realip_module, this
commit switches it to a ternary and avoids duplicating the log and
shovel statements.

[24882]
Merge pull request #29 from sqm/24882-allow-rubycas-to-use-old-and-new-versions-of-nginx-cookbook

#24882 - Add logic to handle older versions of nginx cookbook