I opened a PostgreSQL port by adding a line in /etc/postgresql/10/main/pg_hba.conf
host mydatabase myuser my_ip_adress/32 md