setting IMMICH_API_URL_EXTERNAL
set the
IMMICH_API_URL_EXTERNAL
in env to IMMICH_API_URL_EXTERNAL=/12345
looking at the log for immich-web i see
and the mobile iOS fails when i try https://my.domin.com/12345
10 Replies
IMMICH_API_URL_EXTERNAL
should not be touched unless you have a very custom setuphi Alex.. i am trying to secure my cloudflare tunnel with a WAF where i could check if the url contains a key.. the /api url could be /dsbfsdijfnbsiodfbsdiufb and it would check if this was included and allow connection
i entered /12345 to test
how can i use this env key so i can set my own custom url path? seems just setting that key does not work
Are you thinking of using path for your reverse proxy? like
yourdomain.com/immich
?yes
You need to configure your reverse proxy to rewrite that custom path to /api and leave all the env settings unchanged.
so get rid of the IMMICH_API_URL_EXTERNAL change and leave blank?
oh well Cloudflare doesnt allow the free plan to do regex replace to remove key string from url
but i guess the
IMMICH_API_URL_EXTERNAL
doesnot work or buggyI think it isn't designed to serve this purpose 🤔
i thought it would have set the url path
const endpoint = process.env.IMMICH_API_URL_EXTERNAL || '/api';
if set use that else set it to api
but i found this
export const api = new ImmichApi({ basePath: '/api' });
so its not setable in the env
@Alex can the docker compose link a custom nginx conf to the proxy ??
I edited the default.conf.template with a new rewrite for a custom path like /8256a3343c4204b7
instead of /api and it seems to be working fine.. biut i bet when the docker pull updates i will lose the change..
So looking for a way to link a local nginx default.conf file that the proxy will use even after updatesYou should use your own separate reverse proxy