Ok, I’m editing my comment as what I did write was incorrect.
Currently, using gitlab’s configuration files, I can’t make the two methods of accessing to postgresql local instance working :
It’s either gitlab normal webservice or another service.
The normal way should be to edit [ /etc/gitlab/gitlab.rb ] and find the two distinct lines
postgresql['listen_address'] = ''
postgresql['trust_auth_cidr_addresses'] = 
and change them to :
postgresql['listen_address'] = '*'
postgresql['trust_auth_cidr_addresses'] = ["127.0.0.1/32"]
or whatever IP & IP mask you need to make it trust connections from. IP mask is mandatory or it won’t work.
But if you reconfigure & restart, you could use your other local service to access postgre, but gitlab can’t be accessed anymore.
The only way I found to circumvent this issue is to manually edit postgre conf file var/opt/gitlab/postgresql/data/pg_hba.conf
And add this line at the end of it:
host all all 127.0.0.1/32 trust
Then edit /var/opt/gitlab/postgresql/data/postgresql.conf , find the line:
listen_addresses = ''
And change it to:
listen_addresses = '*'
After that, you just have to execute in a root command line :
# gitlab-ctl restart
And it should work as intended.
Just check Postgre local log to check if anything else went wrong :
# tail /var/log/gitlab/postgresql/current