Use SSL for Heroku Postgres remote connection

When testing locally using Foreman, it will not connect to Heroku Postgres database without SSL.
This behavior is described in this Heroku's article :
https://devcenter.heroku.com/articles/connecting-to-relational-databases-on-heroku-with-java#connecting-to-a-database-remotely