Failed host lookup: 'in.localhost'

Hello everyone.

I have Invoice Ninja deployed through docker.
Almost everything works without problems, except downloading or viewing PDF in the native app (Android or on an Apple Mac).

The error that appears is: Failed host lookup: ‘in.localhost’

However, from the web interface you can download PDFs without problem.

From what I have seen in other threads, the issue is in the config in the docker-compose file, but after trying various ways I cannot resolve it.

In the docker-compose.yml:

- “in5.localhost:” #host and ip

I have also tried putting:

- “in.localhost:” #host and ip

In the env file in APP_URL I have set the URL of a duckdns domain so that I can access it without having to enter IP:Port.

I don’t know what else I can change to solve it.

It is not critical since I can work on the web but if I want to use the native app the download fails.

Thank you.


If you make any changes you’ll need to use the refresh data option on Settings > Device Settings to check the change in the desktop/mobile app.

After the change in the docker-compose.yml file I do a docker compose up -d to recreate the service again and from the Android app I perform the update as you indicate, but the problem persists.

I’m not sure, are you using the standard Docker file?

From what I am investigating, the hosts file of the Invoice Ninja container does not have the extra-host entries that I include in the docker compose.

I access the docker bash but the file is read-only because it is a system file.

I don’t have much experience with Docker but my understanding is that it should work as is without needing any changes.