404 from immich server container root

I'm trying to run Immich without docker-compose (I'm on nixos) so the issues I am having may be fairly unique. I've got all the containers running with a docker bridge network:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
c458b2e04ebe ghcr.io/immich-app/immich-proxy:release "/docker-entrypoint.…" About a minute ago Up About a minute 0.0.0.0:8084->8080/tcp, :::8084->8080/tcp immich_proxy
3717f5fbe02a immich_microservices:release "/bin/sh start-micro…" About a minute ago Up About a minute immich_microservices
a132ae32ffdf immich_server:release "/bin/sh start-serve…" About a minute ago Up About a minute immich_server
0e9f227e5fd2 immich_web:release "/bin/sh entrypoint.…" About a minute ago Up About a minute immich_web
a1bf90792048 ghcr.io/immich-app/immich-machine-learning:release "gunicorn src.main:s…" About a minute ago Up About a minute immich_machine_learning
d118a92ecc0b typesense/typesense:0.24.0 "/opt/typesense-serv…" 54 minutes ago Up 54 minutes 8108/tcp typesense
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
c458b2e04ebe ghcr.io/immich-app/immich-proxy:release "/docker-entrypoint.…" About a minute ago Up About a minute 0.0.0.0:8084->8080/tcp, :::8084->8080/tcp immich_proxy
3717f5fbe02a immich_microservices:release "/bin/sh start-micro…" About a minute ago Up About a minute immich_microservices
a132ae32ffdf immich_server:release "/bin/sh start-serve…" About a minute ago Up About a minute immich_server
0e9f227e5fd2 immich_web:release "/bin/sh entrypoint.…" About a minute ago Up About a minute immich_web
a1bf90792048 ghcr.io/immich-app/immich-machine-learning:release "gunicorn src.main:s…" About a minute ago Up About a minute immich_machine_learning
d118a92ecc0b typesense/typesense:0.24.0 "/opt/typesense-serv…" 54 minutes ago Up 54 minutes 8108/tcp typesense
No errors in the container logs. Inside the proxy container I can I get a 404 on localhost:8080 and when curling the Immich Server container, but its ping endpoint succeeds:
➜ docker exec -it c458b2e04ebe /bin/sh
$ curl localhost:8080
{"statusCode":404,"message":"Cannot GET /","error":"Not Found"}
$ curl immich_server:3001/
{"statusCode":404,"message":"Cannot GET /","error":"Not Found"
$ curl immich_server:3001/server-info/ping
{"res":"pong"}
➜ docker exec -it c458b2e04ebe /bin/sh
$ curl localhost:8080
{"statusCode":404,"message":"Cannot GET /","error":"Not Found"}
$ curl immich_server:3001/
{"statusCode":404,"message":"Cannot GET /","error":"Not Found"
$ curl immich_server:3001/server-info/ping
{"res":"pong"}
38 Replies
Alex Tran
Alex Tran2y ago
So what is the issue you are facing?
solomon
solomonOP2y ago
i get {"statusCode":404,"message":"Cannot GET /","error":"Not Found"} when i try to access the service
Alex Tran
Alex Tran2y ago
that is expected, there is no response from that route you should be able to access the web from IP:8084
solomon
solomonOP2y ago
➜ curl localhost:8084
{"statusCode":404,"message":"Cannot GET /","error":"Not Found"}
➜ curl localhost:8084
{"statusCode":404,"message":"Cannot GET /","error":"Not Found"}
Alex Tran
Alex Tran2y ago
Have you tried to access the web browser from that port?
jrasm91
jrasm912y ago
Did you build some images locally? Why are some prefix with ghcr.io but not the proxy?
solomon
solomonOP2y ago
yeah i have another reverse proxy ontop directing to that port and i get the same 404 from browser when hitting that proxy the images that used entrypoint overrides had to be used as base images and modified because i'm not using docker-compose
jrasm91
jrasm912y ago
Then you probably did that wrong
solomon
solomonOP2y ago
becaseu --entrypoint cant use an array umm, all the logging from all the containers looks fine
jrasm91
jrasm912y ago
Can you curl the web container directly?
solomon
solomonOP2y ago
sure, any specific path?
jrasm91
jrasm912y ago
The root path should return a html page
solomon
solomonOP2y ago
port 3000 right?
jrasm91
jrasm912y ago
I don't think so
solomon
solomonOP2y ago
the env example says IMMICH_WEB_URL=http://immich-web:3000
jrasm91
jrasm912y ago
Oh yes that is correct
solomon
solomonOP2y ago
ok so my immich-web ip is 172.18.0.4
➜ curl 172.18.0.4:3000
➜ curl 172.18.0.4:3000
so yes if that should return html then i have something wrong
Alex Tran
Alex Tran2y ago
I tried on mine and it doesn't return an HTML either
solomon
solomonOP2y ago
this would be so much easier if the entrypoint scripts were either executables or were set in the dockerfiles
jrasm91
jrasm912y ago
Open a PR I don't think anyone is against changing them
Alex Tran
Alex Tran2y ago
try /auth/login
solomon
solomonOP2y ago
auth/login works:
➜ curl 172.18.0.4:3000/auth/login
<!DOCTYPE html>
<html lang="en" class="dark">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />

<link href="../_app/immutable/assets/0.58d44ce7.css" rel="stylesheet"><title>Login - Immich</title><!-- HEAD_svelte-i8gqv5_START --><link rel="icon" href="/_app/immutable/assets/favicon
...
➜ curl 172.18.0.4:3000/auth/login
<!DOCTYPE html>
<html lang="en" class="dark">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />

<link href="../_app/immutable/assets/0.58d44ce7.css" rel="stylesheet"><title>Login - Immich</title><!-- HEAD_svelte-i8gqv5_START --><link rel="icon" href="/_app/immutable/assets/favicon
...
Alex Tran
Alex Tran2y ago
yep that looks correct so everything appear to be wired correctly
solomon
solomonOP2y ago
i can make a PR but that would just mean i dont need to rebuild the images, it wouldn't solve whatever is causing these 404s
Alex Tran
Alex Tran2y ago
From your host, can you curl the IP address of the proxy container with /auth/login path? with the port of course so curl localhost:8084/auth/login
jrasm91
jrasm912y ago
What exactly have you changed with regards to the entry points? All the proxy container does is forward did to the web and server containers
solomon
solomonOP2y ago
i set the CMD to match the entrypoint from the docker compose, thats it
➜ curl localhost:8084/auth/login
{"statusCode":404,"message":"Cannot GET /auth/login","error":"Not Found"}
➜ curl localhost:8084/auth/login
{"statusCode":404,"message":"Cannot GET /auth/login","error":"Not Found"}
jrasm91
jrasm912y ago
It is not forwarding stuff to the web at all Can you look at the proxy logs?
solomon
solomonOP2y ago
i haven't changed the proxy at all
Alex Tran
Alex Tran2y ago
yeah it goes straight to the server
jrasm91
jrasm912y ago
Something is misconfigured
solomon
solomonOP2y ago
yeah i believe it
jrasm91
jrasm912y ago
Can you look at the proxy logs?
solomon
solomonOP2y ago
i copied the compose file which disables logs on the proxy?
logging:
driver: none
logging:
driver: none
jrasm91
jrasm912y ago
There are some environment variables that are set which connect everything together Yeah, remove that and then you should see logs
solomon
solomonOP2y ago
cool. I have to run to the grocery store but i'll do that when i get back. i have discord on my phone so i can answer questiosn while i'm out but not test anything. Thanks so much for the help. I know this isn't the typical immich setup and i appreciate the support
jrasm91
jrasm912y ago
It is possible you just have a wrong env variable Do you set the IMMICH_WEB_URL env? If that was copy/pasted but the value is still set to the immich server then they could explain the proxy sending the requests to the wrong place. If no env is set it should default to the web container.
solomon
solomonOP2y ago
oh wow good catch
$ echo $IMMICH_WEB_URL
http://immich_server:3001
$ echo $IMMICH_WEB_URL
http://immich_server:3001
that solved it!

Did you find this page helpful?