Bug 979740 - Fix Postgres cartridge using $HOME

https://bugzilla.redhat.com/show_bug.cgi?id=979740

The Postgres cartridge was using $HOME in some places, but it should be using $OPENSHIFT_HOMEDIR.
This is causing an unbound variable error.
Merge pull request #3041 from fotioslindiakos/BZ979740

Merged by openshift-bot