Add support for CentOS 7.0. Update postgresql version. Small refactoring