Use items() method to loop over nodegroups/log_granular_levels dictionaries

Otherwise you get an “ValueError: too many values to unpack” exception
when you make use of those entries in your pillar data.
Use items() method instead of iteritems() for Python 3 compatibility

In Python 3, dict.items() is already an iterator while dict.iteritems() no
longer exits. In Python 2, dict.items() is not an iterator but it works
and the small performance hit doesn't really matter for the salt config
pillar data which is really small.
Merge pull request #77 from rhertzog/misc-bugfixes

FIxes for nodegroups/log_granular_levels settings and small cleanups