SQLSTATE[08006] [7] expected authentication request from server, but received _
<p>I configured my application (laravel 5.3) with travis-ci to work with postgresql database, but I got error in matrix build:</p>

<pre><code>SQLSTATE[08006] [7] expected authentication request from server, but received _
</code></pre>

<p>I tried to change pgsql version to 9.4, with no success.</p>

<p>When SSL Mode is set to "prefer", build throws:</p>

<pre><code>SQLSTATE[08006] [7] received invalid response to SSL negotiation: _
</code></pre>

<p>On mysql driver works fine and build passes.
Personally, I prefer postgresql rather than mysql, so I asking for help how to resolve this problem.</p>

<p>Thanks.</p>