Cannot get Nextcloud to connect to MariaDB

Hi, I am new here; first tried the official MariaDB and Nextcloud, then, as many tutorials exist, i tried it with linuxserver/[APP].

I find it super weird, as no one seems to be having the problem that connecting to the database from the nextcloud initial setup is impossible no matter wich images i use, official or linuxserver.

If “advanced” to:
Error while trying to create admin user: Failed to connect to the database: An exception occurred in the driver: SQLSTATE[HY000] [2002] Host is unreachable

After having had “no route to host” before.

I can see in 2021, someone had a similar issue, and a response with someone else that had the same issue, but no-one seemed to care about those two back then ( thread
“Linuxserver/mariadb could not connect to mariadb from host”) … let’s see :wink:

share your compose and container logs

Hi there, it is so funny, that once you reach out for help, and then get a final idea, and that’s the one…

I am running the whole docker installation in an oracle cloud instance. And for whatever reason, in the ingress rules I defined Port 3306 not only as the incoming port, but also as the source port.

I am so sorry for having wasted everyones time :woman_facepalming:

Thank you for the super quick reaction, though! :+1:

So for anyone else having the issue:
Source Ports need to be “all” ( or some port I don’t know )
Destination Port obviously the port wich you set for your MariaDB