[SOLVED] Can I rename the docker containers?
Yes, I've already checked the documentation at https://documentation.immich.app/docs/install/environment-variables
It just doesn't seem like I can, since I can see there are references to the docker container names e.g., in the .env file, there is the environment variable
IMMICH_WEB_URL=http://immich-web:3000
and Note: immich-microservices is bound to 3002, but no references are made
. Can anyone correct me if I'm wrong here?Environment Variables | Immich
Docker Compose
8 Replies
Can you elaborate on the renaming? an example would be helpful
As long as you update the .env to match you should be fine
Sure thing. So this is going to sound nit-picky, but I like to organize my containers based on category (since there is no organizational feature on Docker on my Synology NAS). I would like to do something like this:
immich-proxy:
container_name: utils_immich_proxy
image: ghcr.io/immich-app/immich-proxy:${IMMICHVERSION:-release}
where I would append `"utils..."` as a prefix just to get some alphabetical sorting. Repeat for all the containers. Is that doable?
Something like this:

yeah I think as long as you are using the correct name to replace these container name then you should be fine

Got it, yeah, so I saw that^ which has 5 containers in the list. What about the microservices container, is there an environment variable for that one? Also, would I need to do the same for the redis, typesense, or postgres containers?
The one that show in the URL list is there because we use those dns names to communicate, if it isn't listed then you can use any name essentially
Perfect, that worked!
Just for reference (in case someone else reads this in the future), I had to change the following environment variables in the
.env
file to be:
IMMICH_WEB_URL=http://<your_container_name_here>:3000
IMMICH_SERVER_URL=http://<your_container_name_here>:3001
IMMICH_MACHINE_LEARNING_URL=http://<your_container_name_here>:3003
PUBLIC_IMMICH_SERVER_URL=http://<your_container_name_here>:3001
IMMICH_API_URL_EXTERNAL=/api
REDIS_HOSTNAME=<your_container_name_here>
DB_HOSTNAME=<your_container_name_here>
Obviously replace with whatever the docker container name is and remove the < > symbols