YunoHost-Apps / kresus_ynh

Kresus (personal finance manager) for YunoHost
https://kresus.org/
GNU Affero General Public License v3.0
20 stars 20 forks source link

Error just after installation #104

Closed kidonsky closed 3 years ago

kidonsky commented 3 years ago

Describe the bug

Just after installation, I can not use Kresus due to an error message.

Error when starting the app: No repository for "Access" was found. Looks like this entity is not registered in current "default" connection? Check the console.

Context

Steps to reproduce

Expected behavior

Obtain an usable Kresus app \o/

Logs

App installation https://paste.yunohost.org/raw/vewoluyodu Kresus log when I try to access it https://paste.yunohost.org/ocufafoyoq.log

First research

I reinstalled and made tests for new 0.17.4 version Thanks to nico, I already made some verifications:

Detail

Or maybe more than a detail. My server is ipv6-only. I use a DNS64/NAT64 to communicate with ipv4 servers (like our dear Github)

Thank you for your support !

nicofrand commented 3 years ago

OK, it seems localhost is translated to ::1 with ipv6. Maybe postgresql is not listening on this address but only 127.0.0.1 though.

What is the result of psql -h ::1 -U kresus -c "\l"?

Can you try setting 127.0.0.1 instead of localhost in /var/www/kresus/config.ini then restart Kresus? Or in /etc/hosts adding 127.0.0.1 localhost to see if that works?

kidonsky commented 3 years ago

Well done. psql -h ::1 -U kresus -c "\l" result is as predicted psql: could not connect to server: Connection refused Is the server running on host "::1" and accepting TCP/IP connections on port 5432?

And your trick is the good one. Kresus worked once I replace localhost by 127.0.0.1

So finally, real solution may be to find a generic solution (ipv6 only and ipv4 servers) and implment it in Kresus app.

But for the moment I got my workaround !

Thank you very much !