Configuring pg database