Yeah, 2017 was the last time someone asked about this https://www.helionet.org/index/topic/28532-solved-enable-ssl-in-postgres-database/
It's definitely worth visiting again though since it's been 4 years. SSL has come a long way in that time so surely cpanel has fixed it right?
Unfortunately, I have come to the same conclusion. The version of postgresql that cpanel packages does not have support for ssl compiled in. So I could just compile my own version of postgresql... but then you likely wouldn't be able to create postgresql databases through cpanel or use phppgadmin or anything. If there were any vulnerabilities or anything discovered I would have to recompile it again from source each time it needed to be upgraded.
Sadly, it looks like you'll need a vps for this still.
Nope, I think I got it to work! Try it now with sslmode=require