These are chat archives for ged/ruby-pg

5th
Aug 2017
Michael Granger
@ged
Aug 05 2017 00:16
@manveru Calling connect with sslmode: 'require', sslcompression: 'on' enabled it for me.
[1] pry(main)> c = PG.connect( host: 'localhost', dbname: 'fm', sslmode: 'require', sslcompression: 'on' )
=> #<PG::Connection:0x007ff06c66d8e8>
[2] pry(main)> c.ssl_in_use?
=> true
[3] pry(main)> c.
Display all 184 possibilities? (y or n)
[3] pry(main)> c.ssl_
c.ssl_attribute        c.ssl_attribute_names  c.ssl_attributes       c.ssl_in_use?
[3] pry(main)> c.ssl_attributes
=> {"library"=>"OpenSSL", "key_bits"=>"256", "cipher"=>"ECDHE-RSA-AES256-GCM-SHA384", "compression"=>"on", "protocol"=>"TLSv1.2"}
[4] pry(main)> c.ssl_attribute( 'compression' )
=> "on"
If it doesn't work for you, I can maybe help you troubleshoot, though I'm not as familiar with that part of libpq.
Michael Fellinger
@manveru
Aug 05 2017 00:20
yeah, not working for me :|
it's 2:20am so won't spend time debugging it now
but might be something in the pg server config?
Michael Granger
@ged
Aug 05 2017 00:21
Yeah, that's where I'd start. Turn up server logging and see if it contains anything relevant.