Added pg gem and made some modification in Gemfiles.