puppetlabs/facter — pull request #531 by zaphod42 (2013-08-30 21:30:34+00:00)
Title: (#22349) Read from user's home when non-root

The external facts directory always assumed that the user was root, or at
least had read access to the global facts.d directory. This created problems
for users with restricted permissions when running as non-root. Instead of
trying to handle the permissions problem, which would have made facter run,
this changes facter to follow the same non-root style as puppet, which is to
look in the home directory for a .facter/facts.d external facts directory.
Simply handling the error would have had two undesirable consequences: 1) it
would have hidden a problem from the user and 2) it would have made external
facts cumbersome to use as non-root as the user would always have to specify
--external-dir, which is not currently possible when facter is used by
puppet.