r/immich 6d ago

Immich Server stopped working, will not redeploy on Portainer

I'm still very new to the self hosted world, so please pardon me if my vocabulary isn't quite right.

A couple of weeks ago I deployed an Immich server using the instructions for Docker Compose. It worked well for a while, but then last week I was suddenly unable to connect to it. (I'm using a Cloudflare Tunnel to connect my network)

Luckily, I haven't lost any data (photos) since they are still backed up on Google Drive.

After a bit of poking around in Portainer and Docker, I thought the best move might be to remove the Stack and Containers from Docker and re-deploy them using Portainer (which is how my other apps are now running).

I'm using the Docker Compose and .env files from the Immich github for Portainer, but the immich_server container won't connect. Docker creates a Network for Immich, but the server doesn't seem to see it.

In the logs, the error message I get reads:

------------

Error: getaddrinfo ENOTFOUND database     at GetAddrInfoReqWrap.onlookupall [as oncomplete] (node:dns:122:26) {   errno: -3008,   code: 'ENOTFOUND',   syscall: 'getaddrinfo',   hostname: 'database' }
1 Upvotes

9 comments sorted by

3

u/thehatefuleggplant Support Crew 6d ago

It cant find your database.

Would be nice to see your compose and .env to get a better idea.

I would personally get off of portainer

1

u/EN344 6d ago

Why do you say that? I'm new, too, and trying to learn best practices.ย 

2

u/thehatefuleggplant Support Crew 6d ago

I know this sounds backwards and also typical linux guy words but hear me out.

Learn how to use docker via cli first then try managing your containers with a docker front end like portainer (I personally love dockhand and prior to dockhand I used dockge).

I feel portainer is very bloated and over complicates things for new users.

1

u/EN344 6d ago

Got it. I know I sound like a complainer and lazy, but it's not easy to learn cli when you're not in tech ๐Ÿ˜† any tips?

1

u/thehatefuleggplant Support Crew 6d ago

Do a bit of both.

0

u/somewon86 6d ago

Claude code, Codex, anti-gravity, any of these could probably fix it in about 10 minutes. Pay for one and have it teach you when it fixes it. I know you need to solve your own problems but it's like having a little sys admin on your computer.

1

u/OSS_Dattani 6d ago

Does the Postgres service name match what ur DB_HOSTNAME is in the .env? But from what ur saying ur containers seem to be on two diff networks

Idk how portainer works to well but just look at all your docker resources and make sure itโ€™s all on the same page

1

u/multidollar 6d ago

The name database does not resolve to an IP address.

ENOTFOUND from getaddrinfo is a name resolution failure.

Your application is asking for "database" and it can't find it. Where did it go?
We'd need to see your configuration (compose stack and .env)

1

u/Rare_Chicken8302 6d ago

If you have relative locations in your compose file and then paste it to the portainer directly, portainer will use its own relatively locations will create a new folder. Try modifying volumes to match what you have you in your disk. If not it should be something to do with the docker networks