puppetlabs/puppetlabs-postgresql — pull request #517 by cmurphy (2014-10-31 23:04:07+00:00)
Title: Fix data directory handling

The change introduced in b781849882ee5b36135f8d3abafa449721e19565 added
a complex operation that was not handled correctly for all operating
systems. This fix includes the following corrections:

- Change the systemd config and reload systemd for datadir changes in
RHEL 7, and move configuration for this into
postgresql::server::config since it is managing both the PGDATA and
PGPORT variables
- Make sure Debian systems stop the service before changing the datadir
- Recreate cert links after running initdb in Debian and early ubuntu
- Change the port in the port spec to avoid selinux issues
- Turn off selinux in pgdata spec to avoid selinux issues
- Correct syntax for describing presence of a directory in pgdata spec
- Move the pgdata spec to the end of the tests so that puppet doesn't
have to manager purging and recreating the original datadir
- Update README to describe all caveats of using this parameter