500 Unexpected token < in JSON at position 0 SyntaxError: Unexpected token < in JSON at position 0 #71

Closed
opened 2026-02-04 17:09:54 +03:00 by OVERLORD · 81 comments
Owner

Originally created by @wavesswe on GitHub (May 22, 2022).

Running the docker compose thru Portainer, everyting starts up, I can see that ngnix is running at http://xxxx.xxx.xx.xx:2283/

But get the following issue when trying to access : http://xxxx.xxx.xx.xx:2285/

500
Unexpected token < in JSON at position 0
SyntaxError: Unexpected token < in JSON at position 0

in the logs from the web container

SyntaxError: Unexpected token < in JSON at position 0
at JSON.parse ()
at Proxy. (file:///usr/src/app/build/server/index.js:1586:29)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25)
at async load_node (file:///usr/src/app/build/server/index.js:1605:14)
at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20)
at async resolve (file:///usr/src/app/build/server/index.js:2182:105)
at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-35f923f5.js:7:12)
at async respond (file:///usr/src/app/build/server/index.js:2139:22)
at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3)

Additional context

Is it me that are doing something wrong here or is it broken?

Originally created by @wavesswe on GitHub (May 22, 2022). Running the docker compose thru Portainer, everyting starts up, I can see that ngnix is running at http://xxxx.xxx.xx.xx:2283/ But get the following issue when trying to access : http://xxxx.xxx.xx.xx:2285/ 500 Unexpected token < in JSON at position 0 SyntaxError: Unexpected token < in JSON at position 0 in the logs from the web container SyntaxError: Unexpected token < in JSON at position 0 at JSON.parse (<anonymous>) at Proxy.<anonymous> (file:///usr/src/app/build/server/index.js:1586:29) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25) at async load_node (file:///usr/src/app/build/server/index.js:1605:14) at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20) at async resolve (file:///usr/src/app/build/server/index.js:2182:105) at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-35f923f5.js:7:12) at async respond (file:///usr/src/app/build/server/index.js:2139:22) at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3) **Additional context** Is it me that are doing something wrong here or is it broken?
Author
Owner

@alextran1502 commented on GitHub (May 22, 2022):

Hello, did you specify VITE_SERVER_ENDPOINT= in your .env file?

@alextran1502 commented on GitHub (May 22, 2022): Hello, did you specify `VITE_SERVER_ENDPOINT=` in your `.env` file?
Author
Owner

@alextran1502 commented on GitHub (May 22, 2022):

Additionally, did you include the https://github.com/alextran1502/immich/blob/main/docker/settings/nginx-conf/nginx.conf in your Portainer setup?

@alextran1502 commented on GitHub (May 22, 2022): Additionally, did you include the `https://github.com/alextran1502/immich/blob/main/docker/settings/nginx-conf/nginx.conf` in your Portainer setup?
Author
Owner

@wavesswe commented on GitHub (May 22, 2022):

I did include the .env file. I haven’t added that as extra some where. Where should I put that link?

@wavesswe commented on GitHub (May 22, 2022): I did include the .env file. I haven’t added that as extra some where. Where should I put that link?
Author
Owner

@alextran1502 commented on GitHub (May 22, 2022):

So you have the key VITE_SERVER_ENDPOINT= in your .env file, is that correct?

nginx.conf is the config file that the docker-compose build will look for during the build process, it looks like if you can access the web page/server, you should have specified that file already.

Can you capture the console and network tab in the browser dev tool (F12) for me when you access the web page.

@alextran1502 commented on GitHub (May 22, 2022): So you have the key `VITE_SERVER_ENDPOINT=` in your `.env` file, is that correct? `nginx.conf` is the config file that the docker-compose build will look for during the build process, it looks like if you can access the web page/server, you should have specified that file already. Can you capture the console and network tab in the browser dev tool (F12) for me when you access the web page.
Author
Owner

@wavesswe commented on GitHub (May 22, 2022):

The vite server address is correct, I set the same port as in the example text. The Ngnix page is reachable. But when changing port to access setup I get the message. I will get you the info

@wavesswe commented on GitHub (May 22, 2022): The vite server address is correct, I set the same port as in the example text. The Ngnix page is reachable. But when changing port to access setup I get the message. I will get you the info
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

Can you pull the new image and test it? I did a few bugs fixed and performance optimization earlier this morning.

From the docker directory, run

docker-compose pull immich-web && docker-compose pull immich-server
@alextran1502 commented on GitHub (May 23, 2022): Can you pull the new image and test it? I did a few bugs fixed and performance optimization earlier this morning. From the docker directory, run ```bash docker-compose pull immich-web && docker-compose pull immich-server ```
Author
Owner

@wavesswe commented on GitHub (May 23, 2022):

Hi!

Updated with same results.

from console

@wavesswe commented on GitHub (May 23, 2022): Hi! Updated with same results. from console
Author
Owner

@wavesswe commented on GitHub (May 23, 2022):

rror with Permissions-Policy header: Origin trial controlled feature not enabled: 'interest-cohort'.
:2285/:1 GET http://192.168.x.xx:2285/ 500 (Internal Server Error)
css2:1 GET https://fonts.gstatic.com/s/worksans/v17/QGYsz_wNahGAdqQ43Rh_fKDp.woff2 net::ERR_NAME_NOT_RESOLVED
192.168.x.xx/:1 Access to fetch at 'http://192.168.x.xx:2283/server-info/ping' from origin 'http://192.168.x.xx:2285' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
api-fd31fb07.js:1 GET http://192.168.x.xx:2283/server-info/ping net::ERR_FAILED 404
h @ api-fd31fb07.js:1
p @ api-fd31fb07.js:1
(anonymous) @ __layout.svelte-2ad0b7e4.js:3
setInterval (async)
V @ __layout.svelte-2ad0b7e4.js:3
ke @ index-cf124ca0.js:4
Z @ __layout.svelte-2ad0b7e4.js:3
bt @ start-500b370a.js:1
kt @ start-500b370a.js:1
ke @ index-cf124ca0.js:4
Lt @ start-500b370a.js:1
Pe @ start-500b370a.js:1
_hydrate @ start-500b370a.js:1
await in _hydrate (async)
Yt @ start-500b370a.js:1
(anonymous) @ (index):38
api-fd31fb07.js:1 Uncaught (in promise) TypeError: Failed to fetch
at h (api-fd31fb07.js:1:285)
at p (api-fd31fb07.js:1:401)
at __layout.svelte-2ad0b7e4.js:3:704
h @ api-fd31fb07.js:1
p @ api-fd31fb07.js:1
(anonymous) @ __layout.svelte-2ad0b7e4.js:3
setInterval (async)
V @ __layout.svelte-2ad0b7e4.js:3
ke @ index-cf124ca0.js:4
Z @ __layout.svelte-2ad0b7e4.js:3
bt @ start-500b370a.js:1
kt @ start-500b370a.js:1
ke @ index-cf124ca0.js:4
Lt @ start-500b370a.js:1
Pe @ start-500b370a.js:1
_hydrate @ start-500b370a.js:1
await in _hydrate (async)
Yt @ start-500b370a.js:1
(anonymous) @ (index):38
192.168.3.75/:1 Access to fetch at 'http://192.168.x.xx:2283/server-info/ping' from origin 'http://192.168.x.xx:2285' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
api-fd31fb07.js:1 GET http://192.168.x.xx:2283/server-info/ping net::ERR_FAILED 404
h @ api-fd31fb07.js:1
p @ api-fd31fb07.js:1
(anonymous) @ __layout.svelte-2ad0b7e4.js:3
setInterval (async)
V @ __layout.svelte-2ad0b7e4.js:3
ke @ index-cf124ca0.js:4
Z @ __layout.svelte-2ad0b7e4.js:3
bt @ start-500b370a.js:1
kt @ start-500b370a.js:1
ke @ index-cf124ca0.js:4
Lt @ start-500b370a.js:1
Pe @ start-500b370a.js:1
_hydrate @ start-500b370a.js:1
await in _hydrate (async)
Yt @ start-500b370a.js:1
(anonymous) @ (index):38
api-fd31fb07.js:1 Uncaught (in promise) TypeError: Failed to fetch
at h (api-fd31fb07.js:1:285)
at p (api-fd31fb07.js:1:401)
at __layout.svelte-2ad0b7e4.js:3:704

Updated with same results. IP changed to x.xx but is correct.

@wavesswe commented on GitHub (May 23, 2022): rror with Permissions-Policy header: Origin trial controlled feature not enabled: 'interest-cohort'. :2285/:1 GET http://192.168.x.xx:2285/ 500 (Internal Server Error) css2:1 GET https://fonts.gstatic.com/s/worksans/v17/QGYsz_wNahGAdqQ43Rh_fKDp.woff2 net::ERR_NAME_NOT_RESOLVED 192.168.x.xx/:1 Access to fetch at 'http://192.168.x.xx:2283/server-info/ping' from origin 'http://192.168.x.xx:2285' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled. api-fd31fb07.js:1 GET http://192.168.x.xx:2283/server-info/ping net::ERR_FAILED 404 h @ api-fd31fb07.js:1 p @ api-fd31fb07.js:1 (anonymous) @ __layout.svelte-2ad0b7e4.js:3 setInterval (async) V @ __layout.svelte-2ad0b7e4.js:3 ke @ index-cf124ca0.js:4 Z @ __layout.svelte-2ad0b7e4.js:3 bt @ start-500b370a.js:1 kt @ start-500b370a.js:1 ke @ index-cf124ca0.js:4 Lt @ start-500b370a.js:1 Pe @ start-500b370a.js:1 _hydrate @ start-500b370a.js:1 await in _hydrate (async) Yt @ start-500b370a.js:1 (anonymous) @ (index):38 api-fd31fb07.js:1 Uncaught (in promise) TypeError: Failed to fetch at h (api-fd31fb07.js:1:285) at p (api-fd31fb07.js:1:401) at __layout.svelte-2ad0b7e4.js:3:704 h @ api-fd31fb07.js:1 p @ api-fd31fb07.js:1 (anonymous) @ __layout.svelte-2ad0b7e4.js:3 setInterval (async) V @ __layout.svelte-2ad0b7e4.js:3 ke @ index-cf124ca0.js:4 Z @ __layout.svelte-2ad0b7e4.js:3 bt @ start-500b370a.js:1 kt @ start-500b370a.js:1 ke @ index-cf124ca0.js:4 Lt @ start-500b370a.js:1 Pe @ start-500b370a.js:1 _hydrate @ start-500b370a.js:1 await in _hydrate (async) Yt @ start-500b370a.js:1 (anonymous) @ (index):38 192.168.3.75/:1 Access to fetch at 'http://192.168.x.xx:2283/server-info/ping' from origin 'http://192.168.x.xx:2285' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled. api-fd31fb07.js:1 GET http://192.168.x.xx:2283/server-info/ping net::ERR_FAILED 404 h @ api-fd31fb07.js:1 p @ api-fd31fb07.js:1 (anonymous) @ __layout.svelte-2ad0b7e4.js:3 setInterval (async) V @ __layout.svelte-2ad0b7e4.js:3 ke @ index-cf124ca0.js:4 Z @ __layout.svelte-2ad0b7e4.js:3 bt @ start-500b370a.js:1 kt @ start-500b370a.js:1 ke @ index-cf124ca0.js:4 Lt @ start-500b370a.js:1 Pe @ start-500b370a.js:1 _hydrate @ start-500b370a.js:1 await in _hydrate (async) Yt @ start-500b370a.js:1 (anonymous) @ (index):38 api-fd31fb07.js:1 Uncaught (in promise) TypeError: Failed to fetch at h (api-fd31fb07.js:1:285) at p (api-fd31fb07.js:1:401) at __layout.svelte-2ad0b7e4.js:3:704 Updated with same results. IP changed to x.xx but is correct.
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

hmm interesting, let's isolate the issue of the setup!

Can you let me know what do you see when you enter http://your-ip:2283/server-info/ping into the web browser?

@alextran1502 commented on GitHub (May 23, 2022): hmm interesting, let's isolate the issue of the setup! Can you let me know what do you see when you enter `http://your-ip:2283/server-info/ping` into the web browser?
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

same error here if i access http://your-ip:2283/server-info/ping i got {"res":"pong"}

@spupuz commented on GitHub (May 23, 2022): same error here if i access http://your-ip:2283/server-info/ping i got {"res":"pong"}
Author
Owner

@spupuz commented on GitHub (May 23, 2022):


> web@0.0.1 build
> svelte-kit build

vite v2.9.8 building for production...
transforming...
✓ 687 modules transformed.
rendering chunks...
.svelte-kit/output/client/_app/manifest.json                                  3.94 KiB
.svelte-kit/output/client/_app/error.svelte-f8847189.js                       1.56 KiB / gzip: 0.74 KiB
.svelte-kit/output/client/_app/pages/__layout.svelte-7cc25e42.js              2.23 KiB / gzip: 1.09 KiB
.svelte-kit/output/client/_app/pages/admin/index.svelte-761d93c2.js           16.64 KiB / gzip: 5.97 KiB
.svelte-kit/output/client/_app/pages/auth/register/index.svelte-d5d075c6.js   6.45 KiB / gzip: 2.55 KiB
.svelte-kit/output/client/_app/start-60024a10.js                              24.18 KiB / gzip: 8.81 KiB
.svelte-kit/output/client/_app/pages/auth/login/index.svelte-aace14dc.js      16.03 KiB / gzip: 5.03 KiB
.svelte-kit/output/client/_app/pages/index.svelte-ddb910aa.js                 2.37 KiB / gzip: 1.21 KiB
.svelte-kit/output/client/_app/chunks/index-cf124ca0.js                       11.54 KiB / gzip: 4.78 KiB
.svelte-kit/output/client/_app/chunks/index-7389f52e.js                       0.79 KiB / gzip: 0.48 KiB
.svelte-kit/output/client/_app/chunks/singletons-d1fb5791.js                  0.05 KiB / gzip: 0.07 KiB
.svelte-kit/output/client/_app/chunks/api-a6083403.js                         0.45 KiB / gzip: 0.32 KiB
.svelte-kit/output/client/_app/chunks/constants-1610d5b2.js                   0.05 KiB / gzip: 0.07 KiB
.svelte-kit/output/client/_app/chunks/index-d39cff6c.js                       0.76 KiB / gzip: 0.41 KiB
.svelte-kit/output/client/_app/chunks/auth-api-b3e1ef61.js                    0.43 KiB / gzip: 0.16 KiB
.svelte-kit/output/client/_app/chunks/navigation-bar-cd758090.js              5.91 KiB / gzip: 2.58 KiB
.svelte-kit/output/client/_app/chunks/navigation-0e6511d1.js                  0.17 KiB / gzip: 0.15 KiB
.svelte-kit/output/client/_app/assets/pages/__layout.svelte-2c48307f.css      10.35 KiB / gzip: 2.98 KiB
.svelte-kit/output/client/_app/pages/photos/index.svelte-15e24c77.js          153.84 KiB / gzip: 53.49 KiB
vite v2.9.8 building SSR bundle for production...
transforming...
✓ 51 modules transformed.
rendering chunks...
.svelte-kit/output/server/manifest.json                                         4.36 KiB
.svelte-kit/output/server/index.js                                              75.63 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/index.ts.js              5.82 KiB
.svelte-kit/output/server/entries/endpoints/auth/register/index.ts.js           0.84 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/update.ts.js             1.42 KiB
.svelte-kit/output/server/entries/endpoints/admin/api/create-user.ts.js         0.93 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/api/select-admin.ts.js   1.77 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/api/get-users.ts.js      0.32 KiB
.svelte-kit/output/server/entries/pages/__layout.svelte.js                      1.21 KiB
.svelte-kit/output/server/entries/fallbacks/error.svelte.js                     0.72 KiB
.svelte-kit/output/server/entries/pages/admin/index.svelte.js                   6.69 KiB
.svelte-kit/output/server/entries/pages/auth/login/index.svelte.js              1.94 KiB
.svelte-kit/output/server/entries/pages/auth/register/index.svelte.js           2.86 KiB
.svelte-kit/output/server/entries/pages/index.svelte.js                         1.74 KiB
.svelte-kit/output/server/entries/pages/photos/index.svelte.js                  8.96 KiB
.svelte-kit/output/server/chunks/index-6241e7e7.js                              4.26 KiB
.svelte-kit/output/server/chunks/constants-1610d5b2.js                          0.08 KiB
.svelte-kit/output/server/chunks/api-a833c381.js                                0.86 KiB
.svelte-kit/output/server/chunks/stores-78835596.js                             0.92 KiB
.svelte-kit/output/server/chunks/navigation-bar-07199bb6.js                     3.41 KiB
.svelte-kit/output/server/chunks/hooks-15a5604a.js                              1.12 KiB

Run npm run preview to preview your production build locally.

> Using @sveltejs/adapter-node
  ✔ done
Listening on 0.0.0.0:3000
SyntaxError: Unexpected token e in JSON at position 0
    at JSON.parse (<anonymous>)
    at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
    at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token e in JSON at position 0
    at JSON.parse (<anonymous>)
    at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
    at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token e in JSON at position 0
    at JSON.parse (<anonymous>)
    at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
    at respond (file:///usr/src/app/build/server/index.js:2139:42)
@spupuz commented on GitHub (May 23, 2022): ``` > web@0.0.1 build > svelte-kit build vite v2.9.8 building for production... transforming... ✓ 687 modules transformed. rendering chunks... .svelte-kit/output/client/_app/manifest.json 3.94 KiB .svelte-kit/output/client/_app/error.svelte-f8847189.js 1.56 KiB / gzip: 0.74 KiB .svelte-kit/output/client/_app/pages/__layout.svelte-7cc25e42.js 2.23 KiB / gzip: 1.09 KiB .svelte-kit/output/client/_app/pages/admin/index.svelte-761d93c2.js 16.64 KiB / gzip: 5.97 KiB .svelte-kit/output/client/_app/pages/auth/register/index.svelte-d5d075c6.js 6.45 KiB / gzip: 2.55 KiB .svelte-kit/output/client/_app/start-60024a10.js 24.18 KiB / gzip: 8.81 KiB .svelte-kit/output/client/_app/pages/auth/login/index.svelte-aace14dc.js 16.03 KiB / gzip: 5.03 KiB .svelte-kit/output/client/_app/pages/index.svelte-ddb910aa.js 2.37 KiB / gzip: 1.21 KiB .svelte-kit/output/client/_app/chunks/index-cf124ca0.js 11.54 KiB / gzip: 4.78 KiB .svelte-kit/output/client/_app/chunks/index-7389f52e.js 0.79 KiB / gzip: 0.48 KiB .svelte-kit/output/client/_app/chunks/singletons-d1fb5791.js 0.05 KiB / gzip: 0.07 KiB .svelte-kit/output/client/_app/chunks/api-a6083403.js 0.45 KiB / gzip: 0.32 KiB .svelte-kit/output/client/_app/chunks/constants-1610d5b2.js 0.05 KiB / gzip: 0.07 KiB .svelte-kit/output/client/_app/chunks/index-d39cff6c.js 0.76 KiB / gzip: 0.41 KiB .svelte-kit/output/client/_app/chunks/auth-api-b3e1ef61.js 0.43 KiB / gzip: 0.16 KiB .svelte-kit/output/client/_app/chunks/navigation-bar-cd758090.js 5.91 KiB / gzip: 2.58 KiB .svelte-kit/output/client/_app/chunks/navigation-0e6511d1.js 0.17 KiB / gzip: 0.15 KiB .svelte-kit/output/client/_app/assets/pages/__layout.svelte-2c48307f.css 10.35 KiB / gzip: 2.98 KiB .svelte-kit/output/client/_app/pages/photos/index.svelte-15e24c77.js 153.84 KiB / gzip: 53.49 KiB vite v2.9.8 building SSR bundle for production... transforming... ✓ 51 modules transformed. rendering chunks... .svelte-kit/output/server/manifest.json 4.36 KiB .svelte-kit/output/server/index.js 75.63 KiB .svelte-kit/output/server/entries/endpoints/auth/login/index.ts.js 5.82 KiB .svelte-kit/output/server/entries/endpoints/auth/register/index.ts.js 0.84 KiB .svelte-kit/output/server/entries/endpoints/auth/login/update.ts.js 1.42 KiB .svelte-kit/output/server/entries/endpoints/admin/api/create-user.ts.js 0.93 KiB .svelte-kit/output/server/entries/endpoints/auth/login/api/select-admin.ts.js 1.77 KiB .svelte-kit/output/server/entries/endpoints/auth/login/api/get-users.ts.js 0.32 KiB .svelte-kit/output/server/entries/pages/__layout.svelte.js 1.21 KiB .svelte-kit/output/server/entries/fallbacks/error.svelte.js 0.72 KiB .svelte-kit/output/server/entries/pages/admin/index.svelte.js 6.69 KiB .svelte-kit/output/server/entries/pages/auth/login/index.svelte.js 1.94 KiB .svelte-kit/output/server/entries/pages/auth/register/index.svelte.js 2.86 KiB .svelte-kit/output/server/entries/pages/index.svelte.js 1.74 KiB .svelte-kit/output/server/entries/pages/photos/index.svelte.js 8.96 KiB .svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB .svelte-kit/output/server/chunks/constants-1610d5b2.js 0.08 KiB .svelte-kit/output/server/chunks/api-a833c381.js 0.86 KiB .svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB .svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB .svelte-kit/output/server/chunks/hooks-15a5604a.js 1.12 KiB Run npm run preview to preview your production build locally. > Using @sveltejs/adapter-node ✔ done Listening on 0.0.0.0:3000 SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) ```
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

@spupuz I believe you are also running Immich using Portainer, correct? Can you help me spin up a completely new Immich instance/stack and check if you are still encountering the same issue?

@alextran1502 commented on GitHub (May 23, 2022): @spupuz I believe you are also running Immich using Portainer, correct? Can you help me spin up a completely new Immich instance/stack and check if you are still encountering the same issue?
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

i can try.

Il giorno lun 23 mag 2022 alle ore 14:46 Alex @.***> ha
scritto:

@spupuz https://github.com/spupuz I believe you are also running Immich
using Portainer, correct? Can you help me spin up a completely new Immich
instance/stack and check if you are still encountering the same issue?


Reply to this email directly, view it on GitHub
https://github.com/alextran1502/immich/issues/170#issuecomment-1134631422,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AANELQALSOQEHBPWR5XS5MLVLN4YNANCNFSM5WSRMT3Q
.
You are receiving this because you were mentioned.Message ID:
@.***>

@spupuz commented on GitHub (May 23, 2022): i can try. Il giorno lun 23 mag 2022 alle ore 14:46 Alex ***@***.***> ha scritto: > @spupuz <https://github.com/spupuz> I believe you are also running Immich > using Portainer, correct? Can you help me spin up a completely new Immich > instance/stack and check if you are still encountering the same issue? > > — > Reply to this email directly, view it on GitHub > <https://github.com/alextran1502/immich/issues/170#issuecomment-1134631422>, > or unsubscribe > <https://github.com/notifications/unsubscribe-auth/AANELQALSOQEHBPWR5XS5MLVLN4YNANCNFSM5WSRMT3Q> > . > You are receiving this because you were mentioned.Message ID: > ***@***.***> >
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

database name is hardcoded for this reason can't spin up a double istance from scratch, i just have just one server :)

@spupuz commented on GitHub (May 23, 2022): database name is hardcoded for this reason can't spin up a double istance from scratch, i just have just one server :)
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

Ah. Can you spin up a new instance that is not in Portainer?

I have a feeling this is an issue that related to the server is not updated to the newest version, so the front end is looking for things that the server doesn't have yet. Can you remove the server docker
container and pull it again from Dockerhub?

@alextran1502 commented on GitHub (May 23, 2022): Ah. Can you spin up a new instance that is not in Portainer? I have a feeling this is an issue that related to the server is not updated to the newest version, so the front end is looking for things that the server doesn't have yet. Can you remove the server docker container and pull it again from Dockerhub?
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

Can you help me check this endpoint? http://your-ip:2283/server-info/version

@alextran1502 commented on GitHub (May 23, 2022): Can you help me check this endpoint? `http://your-ip:2283/server-info/version`
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

i can try

@spupuz commented on GitHub (May 23, 2022): > i can try
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

http://your-ip:2283/server-info/version

http://192.168.1.112:2283/server-info/version

{"major":1,"minor":10,"patch":0,"build":14}

@spupuz commented on GitHub (May 23, 2022): > http://your-ip:2283/server-info/version http://192.168.1.112:2283/server-info/version {"major":1,"minor":10,"patch":0,"build":14}
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

hmm, this is the correct response. I will dig into this.

@alextran1502 commented on GitHub (May 23, 2022): hmm, this is the correct response. I will dig into this.
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

With latest docker version server works but since I already have a user can create an admin user, how can I do?

@spupuz commented on GitHub (May 23, 2022): With latest docker version server works but since I already have a user can create an admin user, how can I do?
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

@spupuz After you log in on the web, if you have more than one account on the server, it will ask which account should be made admin. Otherwise, if you have only one account, it will make that account into the admin account :)

@alextran1502 commented on GitHub (May 23, 2022): @spupuz After you log in on the web, if you have more than one account on the server, it will ask which account should be made admin. Otherwise, if you have only one account, it will make that account into the admin account :)
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

@spupuz After you log in on the web, if you have more than one account on the server, it will ask which account should be made admin. Otherwise, if you have only one account, it will make that account into the admin account :)

Cool, just one point web interface does not adapt to browser in phone.

@spupuz commented on GitHub (May 23, 2022): > @spupuz After you log in on the web, if you have more than one account on the server, it will ask which account should be made admin. Otherwise, if you have only one account, it will make that account into the admin account :) Cool, just one point web interface does not adapt to browser in phone.
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

@spupuz Understand, as it is not a priority right now, since you have a mobile app already to view/interact with the backup assets.

@alextran1502 commented on GitHub (May 23, 2022): @spupuz Understand, as it is not a priority right now, since you have a mobile app already to view/interact with the backup assets.
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

Yah I know don't worry I'll put ideas and optmiziation as I see them, proud of being a test this is becoming a real piece of diamond

@spupuz commented on GitHub (May 23, 2022): Yah I know don't worry I'll put ideas and optmiziation as I see them, proud of being a test this is becoming a real piece of diamond
Author
Owner

@alextran1502 commented on GitHub (May 23, 2022):

@spupuz No problem, thank you for doing this. I just want to confirm that you can now access the web interface, correct?

@alextran1502 commented on GitHub (May 23, 2022): @spupuz No problem, thank you for doing this. I just want to confirm that you can now access the web interface, correct?
Author
Owner

@spupuz commented on GitHub (May 23, 2022):

@spupuz No problem, thank you for doing this. I just want to confirm that you can now access the web interface, correct?

Yes I can will test it wider tomorrow with laptop

@spupuz commented on GitHub (May 23, 2022): > @spupuz No problem, thank you for doing this. I just want to confirm that you can now access the web interface, correct? Yes I can will test it wider tomorrow with laptop
Author
Owner

@phamleduy04 commented on GitHub (May 24, 2022):

I have the same problem. When I check the dev console I saw /server-info/ping is returning 404.

The error happen when I changed the VITE_SERVER_ENDPOINT to my public domain. When using IP is fine.

image

@phamleduy04 commented on GitHub (May 24, 2022): I have the same problem. When I check the dev console I saw `/server-info/ping` is returning 404. The error happen when I changed the `VITE_SERVER_ENDPOINT` to my public domain. When using IP is fine. ![image](https://user-images.githubusercontent.com/32657584/169949307-40f69bc5-dc09-48c8-8efd-fd056331d0b4.png)
Author
Owner

@jeanpaulrh commented on GitHub (May 24, 2022):

I also have the same error, but I think caused by a different problem, since if I start docker-compose up without daemon option in the console I see this:

`immich-web_1 | FetchError: request to https://192.168.3.2:2285/192.168.3.2:2283/user/count failed, reason: write EPROTO 140497463036720:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../deps/openssl/openssl/ssl/record/ssl3_record.c:331:
immich-web_1 |
immich-web_1 | at ClientRequest. (file:///usr/src/app/build/shims-eb608bdd.js:6246:11)
immich-web_1 | at ClientRequest.emit (node:events:527:28)
immich-web_1 | at TLSSocket.socketErrorListener (node:_http_client:454:9)
immich-web_1 | at TLSSocket.emit (node:events:527:28)
immich-web_1 | at emitErrorNT (node:internal/streams/destroy:157:8)
immich-web_1 | at emitErrorCloseNT (node:internal/streams/destroy:122:3)
immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:83:21)
immich-web_1 | SyntaxError: Unexpected token < in JSON at position 0
immich-web_1 | at JSON.parse ()
immich-web_1 | at Proxy. (file:///usr/src/app/build/server/index.js:1586:29)
immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:96:5)
immich-web_1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25)
immich-web_1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14)
immich-web_1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20)
immich-web_1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105)
immich-web_1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-0b1f7f3e.js:7:12)
immich-web_1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22)
immich-web_1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3)
immich-web_1 | FetchError: request to https://192.168.3.2:2285/192.168.3.2:2283/user/count failed, reason: write EPROTO 140497463036720:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../deps/openssl/openssl/ssl/record/ssl3_record.c:331:
immich-web_1 |
immich-web_1 | at ClientRequest. (file:///usr/src/app/build/shims-eb608bdd.js:6246:11)
immich-web_1 | at ClientRequest.emit (node:events:527:28)
immich-web_1 | at TLSSocket.socketErrorListener (node:_http_client:454:9)
immich-web_1 | at TLSSocket.emit (node:events:527:28)
immich-web_1 | at emitErrorNT (node:internal/streams/destroy:157:8)
immich-web_1 | at emitErrorCloseNT (node:internal/streams/destroy:122:3)
immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:83:21)
immich-web_1 | SyntaxError: Unexpected token < in JSON at position 0
immich-web_1 | at JSON.parse ()
immich-web_1 | at Proxy. (file:///usr/src/app/build/server/index.js:1586:29)
immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:96:5)
immich-web_1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25)
immich-web_1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14)
immich-web_1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20)
immich-web_1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105)
immich-web_1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-0b1f7f3e.js:7:12)
immich-web_1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22)
immich-web_1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3)
immich-web_1 | FetchError: request to https://192.168.3.2:2285/192.168.3.2:2283/user/count failed, reason: write EPROTO 140497463036720:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../deps/openssl/openssl/ssl/record/ssl3_record.c:331:
immich-web_1 |
immich-web_1 | at ClientRequest. (file:///usr/src/app/build/shims-eb608bdd.js:6246:11)
immich-web_1 | at ClientRequest.emit (node:events:527:28)
immich-web_1 | at TLSSocket.socketErrorListener (node:_http_client:454:9)
immich-web_1 | at TLSSocket.emit (node:events:527:28)
immich-web_1 | at emitErrorNT (node:internal/streams/destroy:157:8)
immich-web_1 | at emitErrorCloseNT (node:internal/streams/destroy:122:3)
immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:83:21)
immich-web_1 | SyntaxError: Unexpected token < in JSON at position 0
immich-web_1 | at JSON.parse ()
immich-web_1 | at Proxy. (file:///usr/src/app/build/server/index.js:1586:29)
immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:96:5)
immich-web_1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25)
immich-web_1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14)
immich-web_1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20)
immich-web_1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105)
immich-web_1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-0b1f7f3e.js:7:12)
immich-web_1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22)
immich-web_1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3)

`
Maybe it's better for me to open a different Bug Report?

@jeanpaulrh commented on GitHub (May 24, 2022): I also have the same error, but I think caused by a different problem, since if I start docker-compose up without daemon option in the console I see this: `immich-web_1 | FetchError: request to https://192.168.3.2:2285/192.168.3.2:2283/user/count failed, reason: write EPROTO 140497463036720:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../deps/openssl/openssl/ssl/record/ssl3_record.c:331: immich-web_1 | immich-web_1 | at ClientRequest.<anonymous> (file:///usr/src/app/build/shims-eb608bdd.js:6246:11) immich-web_1 | at ClientRequest.emit (node:events:527:28) immich-web_1 | at TLSSocket.socketErrorListener (node:_http_client:454:9) immich-web_1 | at TLSSocket.emit (node:events:527:28) immich-web_1 | at emitErrorNT (node:internal/streams/destroy:157:8) immich-web_1 | at emitErrorCloseNT (node:internal/streams/destroy:122:3) immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:83:21) immich-web_1 | SyntaxError: Unexpected token < in JSON at position 0 immich-web_1 | at JSON.parse (<anonymous>) immich-web_1 | at Proxy.<anonymous> (file:///usr/src/app/build/server/index.js:1586:29) immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:96:5) immich-web_1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25) immich-web_1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14) immich-web_1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20) immich-web_1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105) immich-web_1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-0b1f7f3e.js:7:12) immich-web_1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22) immich-web_1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3) immich-web_1 | FetchError: request to https://192.168.3.2:2285/192.168.3.2:2283/user/count failed, reason: write EPROTO 140497463036720:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../deps/openssl/openssl/ssl/record/ssl3_record.c:331: immich-web_1 | immich-web_1 | at ClientRequest.<anonymous> (file:///usr/src/app/build/shims-eb608bdd.js:6246:11) immich-web_1 | at ClientRequest.emit (node:events:527:28) immich-web_1 | at TLSSocket.socketErrorListener (node:_http_client:454:9) immich-web_1 | at TLSSocket.emit (node:events:527:28) immich-web_1 | at emitErrorNT (node:internal/streams/destroy:157:8) immich-web_1 | at emitErrorCloseNT (node:internal/streams/destroy:122:3) immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:83:21) immich-web_1 | SyntaxError: Unexpected token < in JSON at position 0 immich-web_1 | at JSON.parse (<anonymous>) immich-web_1 | at Proxy.<anonymous> (file:///usr/src/app/build/server/index.js:1586:29) immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:96:5) immich-web_1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25) immich-web_1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14) immich-web_1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20) immich-web_1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105) immich-web_1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-0b1f7f3e.js:7:12) immich-web_1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22) immich-web_1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3) immich-web_1 | FetchError: request to https://192.168.3.2:2285/192.168.3.2:2283/user/count failed, reason: write EPROTO 140497463036720:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../deps/openssl/openssl/ssl/record/ssl3_record.c:331: immich-web_1 | immich-web_1 | at ClientRequest.<anonymous> (file:///usr/src/app/build/shims-eb608bdd.js:6246:11) immich-web_1 | at ClientRequest.emit (node:events:527:28) immich-web_1 | at TLSSocket.socketErrorListener (node:_http_client:454:9) immich-web_1 | at TLSSocket.emit (node:events:527:28) immich-web_1 | at emitErrorNT (node:internal/streams/destroy:157:8) immich-web_1 | at emitErrorCloseNT (node:internal/streams/destroy:122:3) immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:83:21) immich-web_1 | SyntaxError: Unexpected token < in JSON at position 0 immich-web_1 | at JSON.parse (<anonymous>) immich-web_1 | at Proxy.<anonymous> (file:///usr/src/app/build/server/index.js:1586:29) immich-web_1 | at processTicksAndRejections (node:internal/process/task_queues:96:5) immich-web_1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25) immich-web_1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14) immich-web_1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20) immich-web_1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105) immich-web_1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-0b1f7f3e.js:7:12) immich-web_1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22) immich-web_1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3) ` Maybe it's better for me to open a different Bug Report?
Author
Owner

@spupuz commented on GitHub (May 24, 2022):

i suppose on the latest docker version there was a regression

`.svelte-kit/output/server/entries/fallbacks/error.svelte.js 0.72 KiB
.svelte-kit/output/server/entries/pages/admin/index.svelte.js 6.69 KiB
.svelte-kit/output/server/entries/pages/auth/login/index.svelte.js 1.94 KiB
.svelte-kit/output/server/entries/pages/auth/register/index.svelte.js 2.86 KiB
.svelte-kit/output/server/entries/pages/index.svelte.js 1.74 KiB
.svelte-kit/output/server/entries/pages/photos/index.svelte.js 8.96 KiB
.svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB
.svelte-kit/output/server/chunks/constants-1610d5b2.js 0.08 KiB
.svelte-kit/output/server/chunks/api-a833c381.js 0.86 KiB
.svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB
.svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB
.svelte-kit/output/server/chunks/hooks-15a5604a.js 1.12 KiB

Run npm run preview to preview your production build locally.

Using @sveltejs/adapter-node
✔ done
Listening on 0.0.0.0:3000

web@0.0.1 build
svelte-kit build

vite v2.9.8 building for production...
transforming...
✓ 687 modules transformed.
rendering chunks...
.svelte-kit/output/client/_app/manifest.json 3.94 KiB
.svelte-kit/output/client/_app/pages/__layout.svelte-7cc25e42.js 2.23 KiB / gzip: 1.09 KiB
.svelte-kit/output/client/_app/error.svelte-f8847189.js 1.56 KiB / gzip: 0.74 KiB
.svelte-kit/output/client/_app/pages/auth/register/index.svelte-d5d075c6.js 6.45 KiB / gzip: 2.55 KiB
.svelte-kit/output/client/_app/start-8447ca62.js 24.18 KiB / gzip: 8.81 KiB
.svelte-kit/output/client/_app/pages/admin/index.svelte-761d93c2.js 16.64 KiB / gzip: 5.97 KiB
.svelte-kit/output/client/_app/pages/index.svelte-ddb910aa.js 2.37 KiB / gzip: 1.21 KiB
.svelte-kit/output/client/_app/pages/auth/login/index.svelte-aace14dc.js 16.03 KiB / gzip: 5.03 KiB
.svelte-kit/output/client/_app/chunks/index-7389f52e.js 0.79 KiB / gzip: 0.48 KiB
.svelte-kit/output/client/_app/chunks/singletons-d1fb5791.js 0.05 KiB / gzip: 0.07 KiB
.svelte-kit/output/client/_app/chunks/index-cf124ca0.js 11.54 KiB / gzip: 4.78 KiB
.svelte-kit/output/client/_app/chunks/api-a6083403.js 0.45 KiB / gzip: 0.32 KiB
.svelte-kit/output/client/_app/chunks/constants-1610d5b2.js 0.05 KiB / gzip: 0.07 KiB
.svelte-kit/output/client/_app/chunks/index-d39cff6c.js 0.76 KiB / gzip: 0.41 KiB
.svelte-kit/output/client/_app/chunks/auth-api-b3e1ef61.js 0.43 KiB / gzip: 0.16 KiB
.svelte-kit/output/client/_app/chunks/navigation-0e6511d1.js 0.17 KiB / gzip: 0.15 KiB
.svelte-kit/output/client/_app/chunks/navigation-bar-cd758090.js 5.91 KiB / gzip: 2.58 KiB
.svelte-kit/output/client/_app/assets/pages/__layout.svelte-2c48307f.css 10.35 KiB / gzip: 2.98 KiB
.svelte-kit/output/client/_app/pages/photos/index.svelte-15e24c77.js 153.84 KiB / gzip: 53.49 KiB
vite v2.9.8 building SSR bundle for production...
transforming...
✓ 51 modules transformed.
rendering chunks...
.svelte-kit/output/server/manifest.json 4.36 KiB
.svelte-kit/output/server/index.js 75.63 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/index.ts.js 5.82 KiB
.svelte-kit/output/server/entries/endpoints/auth/register/index.ts.js 0.84 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/update.ts.js 1.42 KiB
.svelte-kit/output/server/entries/endpoints/admin/api/create-user.ts.js 0.93 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/api/select-admin.ts.js 1.77 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/api/get-users.ts.js 0.32 KiB
.svelte-kit/output/server/entries/pages/__layout.svelte.js 1.21 KiB
.svelte-kit/output/server/entries/fallbacks/error.svelte.js 0.72 KiB
.svelte-kit/output/server/entries/pages/admin/index.svelte.js 6.69 KiB
.svelte-kit/output/server/entries/pages/auth/login/index.svelte.js 1.94 KiB
.svelte-kit/output/server/entries/pages/auth/register/index.svelte.js 2.86 KiB
.svelte-kit/output/server/entries/pages/index.svelte.js 1.74 KiB
.svelte-kit/output/server/entries/pages/photos/index.svelte.js 8.96 KiB
.svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB
.svelte-kit/output/server/chunks/constants-1610d5b2.js 0.08 KiB
.svelte-kit/output/server/chunks/api-a833c381.js 0.86 KiB
.svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB
.svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB
.svelte-kit/output/server/chunks/hooks-15a5604a.js 1.12 KiB

Run npm run preview to preview your production build locally.

Using @sveltejs/adapter-node
✔ done
Listening on 0.0.0.0:3000
SyntaxError: Unexpected token e in JSON at position 0
at JSON.parse ()
at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token e in JSON at position 0
at JSON.parse ()
at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token e in JSON at position 0
at JSON.parse ()
at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token e in JSON at position 0
at JSON.parse ()
at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token e in JSON at position 0
at JSON.parse ()
at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token e in JSON at position 0
at JSON.parse ()
at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73)
at respond (file:///usr/src/app/build/server/index.js:2139:42)`

@spupuz commented on GitHub (May 24, 2022): i suppose on the latest docker version there was a regression `.svelte-kit/output/server/entries/fallbacks/error.svelte.js 0.72 KiB .svelte-kit/output/server/entries/pages/admin/index.svelte.js 6.69 KiB .svelte-kit/output/server/entries/pages/auth/login/index.svelte.js 1.94 KiB .svelte-kit/output/server/entries/pages/auth/register/index.svelte.js 2.86 KiB .svelte-kit/output/server/entries/pages/index.svelte.js 1.74 KiB .svelte-kit/output/server/entries/pages/photos/index.svelte.js 8.96 KiB .svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB .svelte-kit/output/server/chunks/constants-1610d5b2.js 0.08 KiB .svelte-kit/output/server/chunks/api-a833c381.js 0.86 KiB .svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB .svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB .svelte-kit/output/server/chunks/hooks-15a5604a.js 1.12 KiB Run npm run preview to preview your production build locally. > Using @sveltejs/adapter-node ✔ done Listening on 0.0.0.0:3000 > web@0.0.1 build > svelte-kit build vite v2.9.8 building for production... transforming... ✓ 687 modules transformed. rendering chunks... .svelte-kit/output/client/_app/manifest.json 3.94 KiB .svelte-kit/output/client/_app/pages/__layout.svelte-7cc25e42.js 2.23 KiB / gzip: 1.09 KiB .svelte-kit/output/client/_app/error.svelte-f8847189.js 1.56 KiB / gzip: 0.74 KiB .svelte-kit/output/client/_app/pages/auth/register/index.svelte-d5d075c6.js 6.45 KiB / gzip: 2.55 KiB .svelte-kit/output/client/_app/start-8447ca62.js 24.18 KiB / gzip: 8.81 KiB .svelte-kit/output/client/_app/pages/admin/index.svelte-761d93c2.js 16.64 KiB / gzip: 5.97 KiB .svelte-kit/output/client/_app/pages/index.svelte-ddb910aa.js 2.37 KiB / gzip: 1.21 KiB .svelte-kit/output/client/_app/pages/auth/login/index.svelte-aace14dc.js 16.03 KiB / gzip: 5.03 KiB .svelte-kit/output/client/_app/chunks/index-7389f52e.js 0.79 KiB / gzip: 0.48 KiB .svelte-kit/output/client/_app/chunks/singletons-d1fb5791.js 0.05 KiB / gzip: 0.07 KiB .svelte-kit/output/client/_app/chunks/index-cf124ca0.js 11.54 KiB / gzip: 4.78 KiB .svelte-kit/output/client/_app/chunks/api-a6083403.js 0.45 KiB / gzip: 0.32 KiB .svelte-kit/output/client/_app/chunks/constants-1610d5b2.js 0.05 KiB / gzip: 0.07 KiB .svelte-kit/output/client/_app/chunks/index-d39cff6c.js 0.76 KiB / gzip: 0.41 KiB .svelte-kit/output/client/_app/chunks/auth-api-b3e1ef61.js 0.43 KiB / gzip: 0.16 KiB .svelte-kit/output/client/_app/chunks/navigation-0e6511d1.js 0.17 KiB / gzip: 0.15 KiB .svelte-kit/output/client/_app/chunks/navigation-bar-cd758090.js 5.91 KiB / gzip: 2.58 KiB .svelte-kit/output/client/_app/assets/pages/__layout.svelte-2c48307f.css 10.35 KiB / gzip: 2.98 KiB .svelte-kit/output/client/_app/pages/photos/index.svelte-15e24c77.js 153.84 KiB / gzip: 53.49 KiB vite v2.9.8 building SSR bundle for production... transforming... ✓ 51 modules transformed. rendering chunks... .svelte-kit/output/server/manifest.json 4.36 KiB .svelte-kit/output/server/index.js 75.63 KiB .svelte-kit/output/server/entries/endpoints/auth/login/index.ts.js 5.82 KiB .svelte-kit/output/server/entries/endpoints/auth/register/index.ts.js 0.84 KiB .svelte-kit/output/server/entries/endpoints/auth/login/update.ts.js 1.42 KiB .svelte-kit/output/server/entries/endpoints/admin/api/create-user.ts.js 0.93 KiB .svelte-kit/output/server/entries/endpoints/auth/login/api/select-admin.ts.js 1.77 KiB .svelte-kit/output/server/entries/endpoints/auth/login/api/get-users.ts.js 0.32 KiB .svelte-kit/output/server/entries/pages/__layout.svelte.js 1.21 KiB .svelte-kit/output/server/entries/fallbacks/error.svelte.js 0.72 KiB .svelte-kit/output/server/entries/pages/admin/index.svelte.js 6.69 KiB .svelte-kit/output/server/entries/pages/auth/login/index.svelte.js 1.94 KiB .svelte-kit/output/server/entries/pages/auth/register/index.svelte.js 2.86 KiB .svelte-kit/output/server/entries/pages/index.svelte.js 1.74 KiB .svelte-kit/output/server/entries/pages/photos/index.svelte.js 8.96 KiB .svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB .svelte-kit/output/server/chunks/constants-1610d5b2.js 0.08 KiB .svelte-kit/output/server/chunks/api-a833c381.js 0.86 KiB .svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB .svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB .svelte-kit/output/server/chunks/hooks-15a5604a.js 1.12 KiB Run npm run preview to preview your production build locally. > Using @sveltejs/adapter-node ✔ done Listening on 0.0.0.0:3000 SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token e in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-15a5604a.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42)`
Author
Owner

@rantanlan commented on GitHub (May 24, 2022):

@jeanpaulrh

I also have the same error, but I think caused by a different problem, since if I start docker-compose up without daemon option in the console I see this:
` Maybe it's better for me to open a different Bug Report?

I had the same problem, are you sure you have that entry in the .env file correct? I forgot the http:// bevor the ip adress!

VITE_SERVER_ENDPOINT=http://10.1.11.50:2283

@rantanlan commented on GitHub (May 24, 2022): @jeanpaulrh > I also have the same error, but I think caused by a different problem, since if I start docker-compose up without daemon option in the console I see this: > ` Maybe it's better for me to open a different Bug Report? I had the same problem, are you sure you have that entry in the .env file correct? I forgot the http:// bevor the ip adress! VITE_SERVER_ENDPOINT=http://10.1.11.50:2283
Author
Owner

@jeanpaulrh commented on GitHub (May 24, 2022):

I had the same problem, are you sure you have that entry in the .env file correct? I forgot the http:// bevor the ip adress!

VITE_SERVER_ENDPOINT=http://10.1.11.50:2283

You're right! Thanks a lot!

@jeanpaulrh commented on GitHub (May 24, 2022): > I had the same problem, are you sure you have that entry in the .env file correct? I forgot the http:// bevor the ip adress! > > VITE_SERVER_ENDPOINT=http://10.1.11.50:2283 You're right! Thanks a lot!
Author
Owner

@spupuz commented on GitHub (May 24, 2022):

I had the same problem, are you sure you have that entry in the .env file correct? I forgot the http:// bevor the ip adress!
VITE_SERVER_ENDPOINT=http://10.1.11.50:2283

You're right! Thanks a lot!

that's not my case i still got problems

@spupuz commented on GitHub (May 24, 2022): > > I had the same problem, are you sure you have that entry in the .env file correct? I forgot the http:// bevor the ip adress! > > VITE_SERVER_ENDPOINT=http://10.1.11.50:2283 > > You're right! Thanks a lot! that's not my case i still got problems
Author
Owner

@spupuz commented on GitHub (May 24, 2022):

updated the .env and the docker-compose.yml but seems i have problem in connecting to DB

`Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)

immich@1.5.1 prebuild
rimraf dist

immich@1.5.1 build

nest build

immich@1.5.1 start:prod
node dist/main

[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [NestFactory] Starting Nest application...
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] TypeOrmModule dependencies initialized +100ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] JwtModule dependencies initialized +2ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] AppModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] ConfigHostModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] DiscoveryModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] ConfigModule dependencies initialized +12ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] ScheduleModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] ServerInfoModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:31:56 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (1)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:31:59 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (2)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:02 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (3)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:05 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (4)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:08 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (5)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:11 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (6)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:14 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (7)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:17 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (8)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:20 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (9)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:20 PM ERROR [ExceptionHandler] getaddrinfo ENOTFOUND immich_database
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)

immich@1.5.1 prebuild
rimraf dist

immich@1.5.1 build

nest build

immich@1.5.1 start:prod
node dist/main

[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [NestFactory] Starting Nest application...
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] TypeOrmModule dependencies initialized +102ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] JwtModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] AppModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] ConfigHostModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] DiscoveryModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] ConfigModule dependencies initialized +8ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] ScheduleModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] ServerInfoModule dependencies initialized +1ms
[Nest] 51 - 05/24/2022, 12:32:31 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (1)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:34 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (2)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:37 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (3)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
[Nest] 51 - 05/24/2022, 12:32:40 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (4)...
Error: getaddrinfo ENOTFOUND immich_database
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)`

@spupuz commented on GitHub (May 24, 2022): updated the .env and the docker-compose.yml but seems i have problem in connecting to DB `Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) > immich@1.5.1 prebuild > rimraf dist > immich@1.5.1 build  > nest build > immich@1.5.1 start:prod > node dist/main [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [NestFactory] Starting Nest application... [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] TypeOrmModule dependencies initialized +100ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] JwtModule dependencies initialized +2ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] AppModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] ConfigHostModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] DiscoveryModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] ConfigModule dependencies initialized +12ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] ScheduleModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:31:56 PM LOG [InstanceLoader] ServerInfoModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:31:56 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (1)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:31:59 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (2)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:02 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (3)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:05 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (4)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:08 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (5)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:11 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (6)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:14 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (7)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:17 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (8)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:20 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (9)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:20 PM ERROR [ExceptionHandler] getaddrinfo ENOTFOUND immich_database Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) > immich@1.5.1 prebuild > rimraf dist > immich@1.5.1 build  > nest build > immich@1.5.1 start:prod > node dist/main [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [NestFactory] Starting Nest application... [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] TypeOrmModule dependencies initialized +102ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] JwtModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] AppModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] ConfigHostModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] DiscoveryModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] ConfigModule dependencies initialized +8ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] ScheduleModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 51 - 05/24/2022, 12:32:31 PM LOG [InstanceLoader] ServerInfoModule dependencies initialized +1ms [Nest] 51 - 05/24/2022, 12:32:31 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (1)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:34 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (2)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:37 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (3)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [Nest] 51 - 05/24/2022, 12:32:40 PM ERROR [TypeOrmModule] Unable to connect to the database. Retrying (4)... Error: getaddrinfo ENOTFOUND immich_database at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)`
Author
Owner

@alextran1502 commented on GitHub (May 24, 2022):

@spupuz can you help me open a separated issue for the database? As well as providing your redacted .env file. Thanks

@alextran1502 commented on GitHub (May 24, 2022): @spupuz can you help me open a separated issue for the database? As well as providing your redacted .env file. Thanks
Author
Owner

@alextran1502 commented on GitHub (May 24, 2022):

I have the same problem. When I check the dev console I saw /server-info/ping is returning 404.

The error happen when I changed the VITE_SERVER_ENDPOINT to my public domain. When using IP is fine.

image

@phamleduy04 Can you help me open a separate issue for problem accessing the web when put in the public domain to the .env file? Can you help me including your redacted .env file as well? Thanks

@alextran1502 commented on GitHub (May 24, 2022): > I have the same problem. When I check the dev console I saw `/server-info/ping` is returning 404. > > > > The error happen when I changed the `VITE_SERVER_ENDPOINT` to my public domain. When using IP is fine. > > > > ![image](https://user-images.githubusercontent.com/32657584/169949307-40f69bc5-dc09-48c8-8efd-fd056331d0b4.png) > > @phamleduy04 Can you help me open a separate issue for problem accessing the web when put in the public domain to the .env file? Can you help me including your redacted .env file as well? Thanks
Author
Owner

@phamleduy04 commented on GitHub (May 24, 2022):

first time i deploy i can login and setup the web interface.

But now when I tried to redeploy using the old settings the same error popup no matter how I set up the VITE_SERVER_ENDPOINT .env 😢

@phamleduy04 commented on GitHub (May 24, 2022): first time i deploy i can login and setup the web interface. But now when I tried to redeploy using the old settings the same error popup no matter how I set up the `VITE_SERVER_ENDPOINT` .env 😢
Author
Owner

@alextran1502 commented on GitHub (May 24, 2022):

first time i deploy i can login and setup the web interface.

But now when I tried to redeploy using the old settings the same error popup no matter how I set up the VITE_SERVER_ENDPOINT .env 😢

@phamleduy04 I am pretty sure this is the cookie mismatch during the development cycle. Can you navigate to the Application -> Cookie and clear the session in the Browser Dev Tools? I believe this should fix it

@alextran1502 commented on GitHub (May 24, 2022): > first time i deploy i can login and setup the web interface. > > > > But now when I tried to redeploy using the old settings the same error popup no matter how I set up the `VITE_SERVER_ENDPOINT` .env 😢 @phamleduy04 I am pretty sure this is the cookie mismatch during the development cycle. Can you navigate to the Application -> Cookie and clear the session in the Browser Dev Tools? I believe this should fix it
Author
Owner

@alextran1502 commented on GitHub (May 24, 2022):

@wavesswe Can you try clearing the cookie in the browser's Dev tools in the Application -> Cookie tab and see if it fixes the issue

@alextran1502 commented on GitHub (May 24, 2022): @wavesswe Can you try clearing the cookie in the browser's Dev tools in the Application -> Cookie tab and see if it fixes the issue
Author
Owner

@phamleduy04 commented on GitHub (May 25, 2022):

image

The cookie section is empty right now

@phamleduy04 commented on GitHub (May 25, 2022): ![image](https://user-images.githubusercontent.com/32657584/170177511-b683ebb7-b9c5-4848-a733-3f150cffb320.png) The cookie section is empty right now
Author
Owner

@phamleduy04 commented on GitHub (May 25, 2022):

Also now I tried to request to http://my-local-ip:2285/server-info/ping and /version returning 404 Not found

Edit: wrong port, it should be port 2283 :)

@phamleduy04 commented on GitHub (May 25, 2022): ~~Also now I tried to request to `http://my-local-ip:2285/server-info/ping and /version` returning 404 Not found~~ Edit: wrong port, it should be port 2283 :)
Author
Owner

@Nonobis commented on GitHub (May 25, 2022):

Hello,

I am on port 2285 (not using nginx), i have url on port 2285 on .env
Already tryed to delete all cookies, it's not working

immich-immich-web-1 | .svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB
immich-immich-web-1 | .svelte-kit/output/server/chunks/constants-0a775e1b.js 0.07 KiB
immich-immich-web-1 | .svelte-kit/output/server/chunks/api-660e450e.js 0.86 KiB
immich-immich-web-1 | .svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB
immich-immich-web-1 | .svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB
immich-immich-web-1 | .svelte-kit/output/server/chunks/hooks-9b75af5a.js 1.12 KiB
immich-immich-web-1 |
immich-immich-web-1 | Run npm run preview to preview your production build locally.
immich-immich-web-1 |
immich-immich-web-1 | > Using @sveltejs/adapter-node
immich-immich-web-1 | ✔ done
immich-immich-web-1 | Listening on 0.0.0.0:3000
immich-immich-web-1 | SyntaxError: Unexpected token < in JSON at position 0
immich-immich-web-1 | at JSON.parse ()
immich-immich-web-1 | at Proxy. (file:///usr/src/app/build/server/index.js:1586:29)
immich-immich-web-1 | at processTicksAndRejections (node:internal/process/task_queues:96:5)
immich-immich-web-1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25)
immich-immich-web-1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14)
immich-immich-web-1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20)
immich-immich-web-1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105)
immich-immich-web-1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-9b75af5a.js:7:12)
immich-immich-web-1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22)
immich-immich-web-1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3)

@Nonobis commented on GitHub (May 25, 2022): Hello, I am on port 2285 (not using nginx), i have url on port 2285 on .env Already tryed to delete all cookies, it's not working immich-immich-web-1 | .svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/constants-0a775e1b.js 0.07 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/api-660e450e.js 0.86 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/hooks-9b75af5a.js 1.12 KiB immich-immich-web-1 | immich-immich-web-1 | Run npm run preview to preview your production build locally. immich-immich-web-1 | immich-immich-web-1 | > Using @sveltejs/adapter-node immich-immich-web-1 | ✔ done immich-immich-web-1 | Listening on 0.0.0.0:3000 immich-immich-web-1 | **SyntaxError: Unexpected token < in JSON at position 0** immich-immich-web-1 | at JSON.parse (<anonymous>) immich-immich-web-1 | at Proxy.<anonymous> (file:///usr/src/app/build/server/index.js:1586:29) immich-immich-web-1 | at processTicksAndRejections (node:internal/process/task_queues:96:5) immich-immich-web-1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25) immich-immich-web-1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14) immich-immich-web-1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20) immich-immich-web-1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105) immich-immich-web-1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-9b75af5a.js:7:12) immich-immich-web-1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22) immich-immich-web-1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3)
Author
Owner

@alextran1502 commented on GitHub (May 25, 2022):

Also now I tried to request to http://my-local-ip:2285/server-info/ping and /version returning 404 Not found

Edit: wrong port, it should be port 2283 :)

@phamleduy04 Were you able to access the web page, can you share the .env file? Can you try to use a different web browser?

@alextran1502 commented on GitHub (May 25, 2022): > ~Also now I tried to request to `http://my-local-ip:2285/server-info/ping and /version` returning 404 Not found~ > > Edit: wrong port, it should be port 2283 :) @phamleduy04 Were you able to access the web page, can you share the `.env` file? Can you try to use a different web browser?
Author
Owner

@alextran1502 commented on GitHub (May 25, 2022):

Hello,

I am on port 2285 (not using nginx), i have url on port 2285 on .env Already tryed to delete all cookies, it's not working

immich-immich-web-1 | .svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/constants-0a775e1b.js 0.07 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/api-660e450e.js 0.86 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/hooks-9b75af5a.js 1.12 KiB immich-immich-web-1 | immich-immich-web-1 | Run npm run preview to preview your production build locally. immich-immich-web-1 | immich-immich-web-1 | > Using @sveltejs/adapter-node immich-immich-web-1 | heavy_check_mark done immich-immich-web-1 | Listening on 0.0.0.0:3000 immich-immich-web-1 | SyntaxError: Unexpected token < in JSON at position 0 immich-immich-web-1 | at JSON.parse () immich-immich-web-1 | at Proxy. (file:///usr/src/app/build/server/index.js:1586:29) immich-immich-web-1 | at processTicksAndRejections (node:internal/process/task_queues:96:5) immich-immich-web-1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25) immich-immich-web-1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14) immich-immich-web-1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20) immich-immich-web-1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105) immich-immich-web-1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-9b75af5a.js:7:12) immich-immich-web-1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22) immich-immich-web-1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3)

@Nonobis Can you share your .env and docker-compose? Have you performed pulling of new server image with the command docker-compose pull immich-server from the docker folder of the repository?

I saw a different questions on another thread, I am not sure if this issue has been resolved so that you can register another account for your family member

@alextran1502 commented on GitHub (May 25, 2022): > Hello, > > I am on port 2285 (not using nginx), i have url on port 2285 on .env Already tryed to delete all cookies, it's not working > > immich-immich-web-1 | .svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/constants-0a775e1b.js 0.07 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/api-660e450e.js 0.86 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB immich-immich-web-1 | .svelte-kit/output/server/chunks/hooks-9b75af5a.js 1.12 KiB immich-immich-web-1 | immich-immich-web-1 | Run npm run preview to preview your production build locally. immich-immich-web-1 | immich-immich-web-1 | > Using @sveltejs/adapter-node immich-immich-web-1 | heavy_check_mark done immich-immich-web-1 | Listening on 0.0.0.0:3000 immich-immich-web-1 | **SyntaxError: Unexpected token < in JSON at position 0** immich-immich-web-1 | at JSON.parse () immich-immich-web-1 | at Proxy. (file:///usr/src/app/build/server/index.js:1586:29) immich-immich-web-1 | at processTicksAndRejections (node:internal/process/task_queues:96:5) immich-immich-web-1 | at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25) immich-immich-web-1 | at async load_node (file:///usr/src/app/build/server/index.js:1605:14) immich-immich-web-1 | at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20) immich-immich-web-1 | at async resolve (file:///usr/src/app/build/server/index.js:2182:105) immich-immich-web-1 | at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-9b75af5a.js:7:12) immich-immich-web-1 | at async respond (file:///usr/src/app/build/server/index.js:2139:22) immich-immich-web-1 | at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3) @Nonobis Can you share your `.env` and `docker-compose`? Have you performed pulling of new server image with the command `docker-compose pull immich-server` from the `docker` folder of the repository? I saw a different questions on another thread, I am not sure if this issue has been resolved so that you can register another account for your family member
Author
Owner

@Nonobis commented on GitHub (May 25, 2022):

@alextran1502 : i have successfuly created second user with success :) i think i have closed the issue (i don't find it anymore ...)

On Unraid with Docker-Compose Plugin, i don't use ngingx, but caddy as reverse proxy.

Docker-compose.yml

`version: "3.8"

services:

immich_server:
image: altran1502/immich-server:latest
entrypoint: ["/bin/sh", "./entrypoint.sh"]
expose:
- "3000"
volumes:
- ${UPLOAD_LOCATION}:/usr/src/app/upload
env_file:
- .env
ports:
- 3000:3000
environment:
- NODE_ENV=production
depends_on:
- database
- redis
networks:
- immich-network
restart: always

immich_microservices:
image: altran1502/immich-microservices:latest
entrypoint: ["/bin/sh", "./entrypoint.sh"]
expose:
- "3001"
ports:
- 3001:3001
volumes:
- ${UPLOAD_LOCATION}:/usr/src/app/upload
env_file:
- .env
environment:
- NODE_ENV=production
depends_on:
- database
- redis
networks:
- immich-network
restart: always

immich-web:
image: altran1502/immich-web:latest
entrypoint: ["/bin/sh", "./entrypoint.sh"]
env_file:
- .env
depends_on:
- database
- redis
expose:
- "2285"
ports:
- 2285:3000
networks:
- immich-network
restart: always

redis:
container_name: immich_redis
restart: always
image: redis:6.2
networks:
- immich-network

database:
container_name: immich_postgres
image: postgres:14
restart: always
env_file:
- .env
environment:
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_USER: ${DB_USERNAME}
POSTGRES_DB: ${DB_DATABASE_NAME}
PG_DATA: /var/lib/postgresql/data
volumes:
- ${IMMICH_DB_DATA}:/var/lib/postgresql/data
ports:
- 5432:5432
networks:
- immich-network

networks:
immich-network:

.Env (removed private data )

`DB_USERNAME=postgres

DB_PASSWORD=postgres

DB_DATABASE_NAME=immich

IMMICH_DB_DATA=/mnt/user/Databases/immich_pg

UPLOAD_LOCATION=/mnt/user/Pictures

JWT_SECRET=[REMOVED]

ENABLE_MAPBOX=true

MAPBOX_KEY=[REMOVED]

VITE_SERVER_ENDPOINT=http://arda:2285`

@Nonobis commented on GitHub (May 25, 2022): @alextran1502 : i have successfuly created second user with success :) i think i have closed the issue (i don't find it anymore ...) On Unraid with Docker-Compose Plugin, i don't use ngingx, but caddy as reverse proxy. **Docker-compose.yml** `version: "3.8" services: immich_server: image: altran1502/immich-server:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] expose: - "3000" volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload env_file: - .env ports: - 3000:3000 environment: - NODE_ENV=production depends_on: - database - redis networks: - immich-network restart: always immich_microservices: image: altran1502/immich-microservices:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] expose: - "3001" ports: - 3001:3001 volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload env_file: - .env environment: - NODE_ENV=production depends_on: - database - redis networks: - immich-network restart: always immich-web: image: altran1502/immich-web:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] env_file: - .env depends_on: - database - redis expose: - "2285" ports: - 2285:3000 networks: - immich-network restart: always redis: container_name: immich_redis restart: always image: redis:6.2 networks: - immich-network database: container_name: immich_postgres image: postgres:14 restart: always env_file: - .env environment: POSTGRES_PASSWORD: ${DB_PASSWORD} POSTGRES_USER: ${DB_USERNAME} POSTGRES_DB: ${DB_DATABASE_NAME} PG_DATA: /var/lib/postgresql/data volumes: - ${IMMICH_DB_DATA}:/var/lib/postgresql/data ports: - 5432:5432 networks: - immich-network networks: immich-network: **.Env (removed private data )** `DB_USERNAME=postgres DB_PASSWORD=postgres DB_DATABASE_NAME=immich IMMICH_DB_DATA=/mnt/user/Databases/immich_pg UPLOAD_LOCATION=/mnt/user/Pictures JWT_SECRET=[REMOVED] ENABLE_MAPBOX=true MAPBOX_KEY=[REMOVED] VITE_SERVER_ENDPOINT=http://arda:2285`
Author
Owner

@spupuz commented on GitHub (May 25, 2022):

@alextran1502 : i have successfuly created second user with success :) i think i have closed the issue (i don't find it anymore ...)

On Unraid with Docker-Compose Plugin, i don't use ngingx, but caddy as reverse proxy.

Docker-compose.yml

`version: "3.8"

services:

immich_server: image: altran1502/immich-server:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] expose: - "3000" volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload env_file: - .env ports: - 3000:3000 environment: - NODE_ENV=production depends_on: - database - redis networks: - immich-network restart: always

immich_microservices: image: altran1502/immich-microservices:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] expose: - "3001" ports: - 3001:3001 volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload env_file: - .env environment: - NODE_ENV=production depends_on: - database - redis networks: - immich-network restart: always

immich-web: image: altran1502/immich-web:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] env_file: - .env depends_on: - database - redis expose: - "2285" ports: - 2285:3000 networks: - immich-network restart: always

redis: container_name: immich_redis restart: always image: redis:6.2 networks: - immich-network

database: container_name: immich_postgres image: postgres:14 restart: always env_file: - .env environment: POSTGRES_PASSWORD: ${DB_PASSWORD} POSTGRES_USER: ${DB_USERNAME} POSTGRES_DB: ${DB_DATABASE_NAME} PG_DATA: /var/lib/postgresql/data volumes: - ${IMMICH_DB_DATA}:/var/lib/postgresql/data ports: - 5432:5432 networks: - immich-network

networks: immich-network:

.Env (removed private data )

`# Database DB_USERNAME=postgres DB_PASSWORD=postgres DB_DATABASE_NAME=immich IMMICH_DB_DATA=/mnt/user/Databases/immich_pg

Upload File Config

UPLOAD_LOCATION=/mnt/user/Pictures

JWT SECRET

JWT_SECRET=[REMOVED]

MAPBOX

ENABLE_MAPBOX is either true of false -> if true, you have to provide MAPBOX_KEY

ENABLE_MAPBOX=true MAPBOX_KEY=[REMOVED]`

###################################################################################

WEB

###################################################################################

This is the URL of your vm/server where you host Immich, so that the web frontend

know where can it make the request to.

For example: If your server IP address is 10.1.11.50, the environment variable will

be VITE_SERVER_ENDPOINT=http://10.1.11.50:2283

VITE_SERVER_ENDPOINT=http://arda:2285`

i have another istanza of nginx so can i remove the one in the docker compose? @alextran1502

@spupuz commented on GitHub (May 25, 2022): > @alextran1502 : i have successfuly created second user with success :) i think i have closed the issue (i don't find it anymore ...) > > On Unraid with Docker-Compose Plugin, i don't use ngingx, but caddy as reverse proxy. > > **Docker-compose.yml** > > `version: "3.8" > > services: > > immich_server: image: altran1502/immich-server:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] expose: - "3000" volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload env_file: - .env ports: - 3000:3000 environment: - NODE_ENV=production depends_on: - database - redis networks: - immich-network restart: always > > immich_microservices: image: altran1502/immich-microservices:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] expose: - "3001" ports: - 3001:3001 volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload env_file: - .env environment: - NODE_ENV=production depends_on: - database - redis networks: - immich-network restart: always > > immich-web: image: altran1502/immich-web:latest entrypoint: ["/bin/sh", "./entrypoint.sh"] env_file: - .env depends_on: - database - redis expose: - "2285" ports: - 2285:3000 networks: - immich-network restart: always > > redis: container_name: immich_redis restart: always image: redis:6.2 networks: - immich-network > > database: container_name: immich_postgres image: postgres:14 restart: always env_file: - .env environment: POSTGRES_PASSWORD: ${DB_PASSWORD} POSTGRES_USER: ${DB_USERNAME} POSTGRES_DB: ${DB_DATABASE_NAME} PG_DATA: /var/lib/postgresql/data volumes: - ${IMMICH_DB_DATA}:/var/lib/postgresql/data ports: - 5432:5432 networks: - immich-network > > networks: immich-network: > > **.Env (removed private data )** > > `# Database DB_USERNAME=postgres DB_PASSWORD=postgres DB_DATABASE_NAME=immich IMMICH_DB_DATA=/mnt/user/Databases/immich_pg > > # Upload File Config > UPLOAD_LOCATION=/mnt/user/Pictures > > # JWT SECRET > JWT_SECRET=[REMOVED] > > # MAPBOX > ## ENABLE_MAPBOX is either true of false -> if true, you have to provide MAPBOX_KEY > ENABLE_MAPBOX=true MAPBOX_KEY=[REMOVED]` > > ################################################################################### > > # WEB > ################################################################################### > > # This is the URL of your vm/server where you host Immich, so that the web frontend > # know where can it make the request to. > # For example: If your server IP address is 10.1.11.50, the environment variable will > # be VITE_SERVER_ENDPOINT=http://10.1.11.50:2283 > VITE_SERVER_ENDPOINT=[http://arda:2285`](http://arda:2285%60) i have another istanza of nginx so can i remove the one in the docker compose? @alextran1502
Author
Owner

@alextran1502 commented on GitHub (May 25, 2022):

@spupuz @Nonobis The Nginx in the stack is for load balancing if you create more instances of the immich-server if you have ten of thousands of pictures. You can leave it without any issue since it doesn't interfere with other ports

@alextran1502 commented on GitHub (May 25, 2022): @spupuz @Nonobis The Nginx in the stack is for load balancing if you create more instances of the immich-server if you have ten of thousands of pictures. You can leave it without any issue since it doesn't interfere with other ports
Author
Owner

@spupuz commented on GitHub (May 25, 2022):

@spupuz @Nonobis The Nginx in the stack is for load balancing if you create more instances of the immich-server if you have ten of thousands of pictures. You can leave it without any issue since it doesn't interfere with other ports

yeah i was trying to understand how to optimize in oder to not overload my small server
:D i have a total of 39 container running

@spupuz commented on GitHub (May 25, 2022): > @spupuz @Nonobis The Nginx in the stack is for load balancing if you create more instances of the immich-server if you have ten of thousands of pictures. You can leave it without any issue since it doesn't interfere with other ports yeah i was trying to understand how to optimize in oder to not overload my small server :D i have a total of 39 container running
Author
Owner

@Nonobis commented on GitHub (May 25, 2022):

@[alextran1502 : Got web login page with nginx in docker stack :) Thanks :)

@Nonobis commented on GitHub (May 25, 2022): @[alextran1502 : Got web login page with nginx in docker stack :) Thanks :)
Author
Owner

@phamleduy04 commented on GitHub (May 26, 2022):

Also now I tried to request to http://my-local-ip:2285/server-info/ping and /version returning 404 Not found
Edit: wrong port, it should be port 2283 :)

@phamleduy04 Were you able to access the web page, can you share the .env file? Can you try to use a different web browser?

I tried with multiple browser and machine but still error.

This is my .env

###################################################################################
# Database
###################################################################################

DB_HOSTNAME=immich_postgres
DB_USERNAME=postgres
DB_PASSWORD=postgres
DB_DATABASE_NAME=immich





###################################################################################
# Redis
###################################################################################

REDIS_HOSTNAME=immich_redis





###################################################################################
# Upload File Config
###################################################################################

UPLOAD_LOCATION=/home/dui/immich/photos




###################################################################################
# JWT SECRET
###################################################################################

JWT_SECRET=<REMOVED>




###################################################################################
# MAPBOX
####################################################################################

# ENABLE_MAPBOX is either true of false -> if true, you have to provide MAPBOX_KEY
ENABLE_MAPBOX=true
MAPBOX_KEY=<REMOVED>




###################################################################################
# WEB
###################################################################################

# This is the URL of your vm/server where you host Immich, so that the web frontend
# know where can it make the request to.
# For example: If your server IP address is 10.1.11.50, the environment variable will
# be VITE_SERVER_ENDPOINT=http://10.1.11.50:2283

VITE_SERVER_ENDPOINT=REMOVED
@phamleduy04 commented on GitHub (May 26, 2022): > > ~Also now I tried to request to `http://my-local-ip:2285/server-info/ping and /version` returning 404 Not found~ > > Edit: wrong port, it should be port 2283 :) > > @phamleduy04 Were you able to access the web page, can you share the `.env` file? Can you try to use a different web browser? I tried with multiple browser and machine but still error. This is my .env ``` ################################################################################### # Database ################################################################################### DB_HOSTNAME=immich_postgres DB_USERNAME=postgres DB_PASSWORD=postgres DB_DATABASE_NAME=immich ################################################################################### # Redis ################################################################################### REDIS_HOSTNAME=immich_redis ################################################################################### # Upload File Config ################################################################################### UPLOAD_LOCATION=/home/dui/immich/photos ################################################################################### # JWT SECRET ################################################################################### JWT_SECRET=<REMOVED> ################################################################################### # MAPBOX #################################################################################### # ENABLE_MAPBOX is either true of false -> if true, you have to provide MAPBOX_KEY ENABLE_MAPBOX=true MAPBOX_KEY=<REMOVED> ################################################################################### # WEB ################################################################################### # This is the URL of your vm/server where you host Immich, so that the web frontend # know where can it make the request to. # For example: If your server IP address is 10.1.11.50, the environment variable will # be VITE_SERVER_ENDPOINT=http://10.1.11.50:2283 VITE_SERVER_ENDPOINT=REMOVED ```
Author
Owner

@alextran1502 commented on GitHub (May 26, 2022):

@phamleduy04 I think this might be your reverse proxy setup that causes the problem.

@alextran1502 commented on GitHub (May 26, 2022): @phamleduy04 I think this might be your reverse proxy setup that causes the problem.
Author
Owner

@phamleduy04 commented on GitHub (May 26, 2022):

okay so i found the problem is the VITE_SERVER_ENDPOINT in .env file. I should put my local IP instead and just forward using traefik to reverse proxy :)

@phamleduy04 commented on GitHub (May 26, 2022): okay so i found the problem is the `VITE_SERVER_ENDPOINT` in .env file. I should put my local IP instead and just forward using traefik to reverse proxy :)
Author
Owner

@phamleduy04 commented on GitHub (May 26, 2022):

So this is how I do for production env.
I use the reverse proxy (traefik in my case) to map:

  • immich.your-domain.example to <IP>:2285 and this is your web app to see photos.
  • immich-api.your-domain.example to <IP>:2283 and this will be the VITE_SERVER_ENDPOINT and the URL put in the phone app.

Hope this helps 👍

@phamleduy04 commented on GitHub (May 26, 2022): So this is how I do for production env. I use the reverse proxy (traefik in my case) to map: - `immich.your-domain.example` to `<IP>:2285` and this is your web app to see photos. - `immich-api.your-domain.example` to `<IP>:2283` and this will be the `VITE_SERVER_ENDPOINT` and the URL put in the phone app. Hope this helps 👍
Author
Owner

@mada199122 commented on GitHub (May 27, 2022):

This is my compose stack but I'm not able to get it works always

500
Unexpected token a in JSON at position 0
SyntaxError: Unexpected token a in JSON at position 0
services:

  immich-server:
    image: altran1502/immich-server:latest
    container_name: "immich-server"
    entrypoint: ["/bin/sh", "./entrypoint.sh"]
    networks:
      immich:
    expose:
      - 3000 
    volumes:
      - "/REDACTED/Upload:/usr/src/app/upload"
    env_file:
      - /REDACTED/.env
    environment:
      - NODE_ENV=production
    depends_on:
      - immich_redis
      - immich_postgres
    restart: unless-stopped


  immich-web:
    image: altran1502/immich-web:latest
    container_name: "immich-web"
    entrypoint: ["/bin/sh", "./entrypoint.sh"]
    networks:
      immich:
    env_file:
      - /REDACTED/.env
    ports:
      - 2285:3000
    restart: unless-stopped

  immich_redis:
    container_name: "immich_redis"
    image: redis:6.2
    networks:
      immich:
    volumes:
      - "/REDACTED:/data"
    restart: unless-stopped
    

  immich_postgres:
    container_name: "immich_postgres"
    image: postgres:14
    networks:
      immich:
    env_file:
      - /REDACTED/.env
    environment:
      POSTGRES_PASSWORD: ${IMMICH_PG_DB_PASSWORD}
      POSTGRES_USER: ${IMMICH_PG_DB_USERNAME}
      POSTGRES_DB: ${IMMICH_PG_DB_DATABASE_NAME}
      PG_DATA: /var/lib/postgresql/data
    volumes:
      - "/REDACTED/:/var/lib/postgresql/data"
    restart: unless-stopped


networks:

  immich:
    driver: bridge
    name: "immich"
    internal: false
    ipam:
      driver: default
      config:
        - subnet: 172.23.25.0/24
          gateway: 172.23.25.1

THE env file instead is this one

DB_HOSTNAME=immich_postgres
###################################################################################
# Database
###################################################################################
DB_USERNAME=XXXXXXXXXXXXX
DB_PASSWORD=XXXXXXXXXXXXX
DB_DATABASE_NAME=XXXXXXXXXXXXX



###################################################################################
# Upload File Config
###################################################################################
UPLOAD_LOCATION=./upload



###################################################################################
# JWT SECRET
###################################################################################
JWT_SECRET=XXXXXXXXXXXXX


###################################################################################
# MAPBOX
####################################################################################
# ENABLE_MAPBOX is either true of false -> if true, you have to provide MAPBOX_KEY
ENABLE_MAPBOX=true
MAPBOX_KEY=XXXXXXXXXXXXX



###################################################################################
# WEB
###################################################################################
# This is the URL of your vm/server where you host Immich, so that the web frontend
# know where can it make the request to.
# For example: If your server IP address is 10.1.11.50, the environment variable will
# be VITE_SERVER_ENDPOINT=http://10.1.11.50:2283
VITE_SERVER_ENDPOINT=http://IP-OF-MY-SERVER:2283


###################################################################################
# Redis
###################################################################################

REDIS_HOSTNAME=immich_redis

Why should VITE_SERVER_ENDPOINT point to port 2283 if it is not present in the compose?

In any cane here the log

IMMICH SERVER

> immich@1.5.1 prebuild
> rimraf dist


> immich@1.5.1 build

> nest build


> immich@1.5.1 start:prod
> node dist/main

[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [NestFactory] Starting Nest application...
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] TypeOrmModule dependencies initialized +169ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] JwtModule dependencies initialized +2ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] AppModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] ConfigHostModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] DiscoveryModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] ConfigModule dependencies initialized +12ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] ScheduleModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] BullModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] BullModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:09 AM     LOG [InstanceLoader] ServerInfoModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] TypeOrmCoreModule dependencies initialized +301ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] TypeOrmModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] TypeOrmModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] TypeOrmModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] TypeOrmModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] TypeOrmModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] CommunicationModule dependencies initialized +4ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] ImmichJwtModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] ScheduleTasksModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] BackgroundTaskModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] ImageOptimizeModule dependencies initialized +4ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] DeviceInfoModule dependencies initialized +2ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] SharingModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] AuthModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] UserModule dependencies initialized +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [InstanceLoader] AssetModule dependencies initialized +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RoutesResolver] AppController {/}: +20ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/, GET} route +5ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RoutesResolver] UserController {/user}: +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/user, GET} route +2ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/user, POST} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/user/count, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/user, PUT} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RoutesResolver] AssetController {/asset}: +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/upload, POST} route +2ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/download, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/file, GET} route +2ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/thumbnail/:assetId, GET} route +2ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/allObjects, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/allLocation, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/searchTerm, GET} route +2ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/search, POST} route +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/:deviceId, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset/assetById/:assetId, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/asset, DELETE} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RoutesResolver] AuthController {/auth}: +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/auth/login, POST} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/auth/admin-sign-up, POST} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/auth/validateToken, POST} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RoutesResolver] DeviceInfoController {/device-info}: +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/device-info, POST} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/device-info, PATCH} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RoutesResolver] ServerInfoController {/server-info}: +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/server-info, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/server-info/ping, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/server-info/mapbox, GET} route +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/server-info/version, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RoutesResolver] SharingController {/shared}: +0ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/createAlbum, POST} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/addUsers, POST} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/addAssets, POST} route +3ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/allSharedAlbums, GET} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/:albumId, GET} route +2ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/removeAssets, DELETE} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/:albumId, DELETE} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/leaveAlbum/:albumId, DELETE} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [RouterExplorer] Mapped {/shared/updateInfo, PATCH} route +1ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [NestApplication] Nest application successfully started +41ms
[Nest] 52  - 05/27/2022, 6:32:10 AM     LOG [IMMICH SERVER] Running Immich Server in PRODUCTION environment 

Here IMMICH WEB

> web@0.0.1 build
> svelte-kit build

vite v2.9.8 building for production...
transforming...
✓ 687 modules transformed.
rendering chunks...
.svelte-kit/output/client/_app/manifest.json                                  3.94 KiB
.svelte-kit/output/client/_app/start-7968382e.js                              24.18 KiB / gzip: 8.81 KiB
.svelte-kit/output/client/_app/pages/auth/login/index.svelte-aace14dc.js      16.03 KiB / gzip: 5.03 KiB
.svelte-kit/output/client/_app/error.svelte-f8847189.js                       1.56 KiB / gzip: 0.74 KiB
.svelte-kit/output/client/_app/pages/admin/index.svelte-9879ae55.js           16.64 KiB / gzip: 5.97 KiB
.svelte-kit/output/client/_app/pages/__layout.svelte-200db308.js              2.23 KiB / gzip: 1.09 KiB
.svelte-kit/output/client/_app/pages/index.svelte-43ca08b8.js                 2.37 KiB / gzip: 1.21 KiB
.svelte-kit/output/client/_app/chunks/index-cf124ca0.js                       11.54 KiB / gzip: 4.78 KiB
.svelte-kit/output/client/_app/chunks/singletons-d1fb5791.js                  0.05 KiB / gzip: 0.07 KiB
.svelte-kit/output/client/_app/chunks/api-8119291a.js                         0.45 KiB / gzip: 0.32 KiB
.svelte-kit/output/client/_app/chunks/constants-f22e011b.js                   0.05 KiB / gzip: 0.06 KiB
.svelte-kit/output/client/_app/chunks/index-d39cff6c.js                       0.76 KiB / gzip: 0.41 KiB
.svelte-kit/output/client/_app/chunks/navigation-bar-cd758090.js              5.91 KiB / gzip: 2.58 KiB
.svelte-kit/output/client/_app/chunks/auth-api-b3e1ef61.js                    0.43 KiB / gzip: 0.16 KiB
.svelte-kit/output/client/_app/chunks/navigation-0e6511d1.js                  0.17 KiB / gzip: 0.15 KiB
.svelte-kit/output/client/_app/assets/pages/__layout.svelte-2c48307f.css      10.35 KiB / gzip: 2.98 KiB
.svelte-kit/output/client/_app/chunks/index-7389f52e.js                       0.79 KiB / gzip: 0.48 KiB
.svelte-kit/output/client/_app/pages/auth/register/index.svelte-ea0c4574.js   6.45 KiB / gzip: 2.55 KiB
.svelte-kit/output/client/_app/pages/photos/index.svelte-88ebb3cf.js          153.84 KiB / gzip: 53.48 KiB
vite v2.9.8 building SSR bundle for production...
transforming...
✓ 51 modules transformed.
rendering chunks...
.svelte-kit/output/server/manifest.json                                         4.36 KiB
.svelte-kit/output/server/index.js                                              75.63 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/index.ts.js              5.82 KiB
.svelte-kit/output/server/entries/endpoints/auth/register/index.ts.js           0.84 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/update.ts.js             1.42 KiB
.svelte-kit/output/server/entries/endpoints/admin/api/create-user.ts.js         0.93 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/api/select-admin.ts.js   1.77 KiB
.svelte-kit/output/server/entries/endpoints/auth/login/api/get-users.ts.js      0.32 KiB
.svelte-kit/output/server/entries/pages/__layout.svelte.js                      1.21 KiB
.svelte-kit/output/server/entries/fallbacks/error.svelte.js                     0.72 KiB
.svelte-kit/output/server/entries/pages/admin/index.svelte.js                   6.69 KiB
.svelte-kit/output/server/entries/pages/auth/login/index.svelte.js              1.94 KiB
.svelte-kit/output/server/entries/pages/auth/register/index.svelte.js           2.86 KiB
.svelte-kit/output/server/entries/pages/index.svelte.js                         1.74 KiB
.svelte-kit/output/server/entries/pages/photos/index.svelte.js                  8.96 KiB
.svelte-kit/output/server/chunks/index-6241e7e7.js                              4.26 KiB
.svelte-kit/output/server/chunks/constants-f22e011b.js                          0.08 KiB
.svelte-kit/output/server/chunks/api-75d724dc.js                                0.86 KiB
.svelte-kit/output/server/chunks/stores-78835596.js                             0.92 KiB
.svelte-kit/output/server/chunks/navigation-bar-07199bb6.js                     3.41 KiB
.svelte-kit/output/server/chunks/hooks-3418e942.js                              1.12 KiB

Run npm run preview to preview your production build locally.

> Using @sveltejs/adapter-node
  ✔ done
Listening on 0.0.0.0:3000
SyntaxError: Unexpected token a in JSON at position 0
    at JSON.parse (<anonymous>)
    at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73)
    at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token a in JSON at position 0
    at JSON.parse (<anonymous>)
    at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73)
    at respond (file:///usr/src/app/build/server/index.js:2139:42)
SyntaxError: Unexpected token a in JSON at position 0
    at JSON.parse (<anonymous>)
    at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73)
    at respond (file:///usr/src/app/build/server/index.js:2139:42)
@mada199122 commented on GitHub (May 27, 2022): This is my compose stack but I'm not able to get it works always ``` 500 Unexpected token a in JSON at position 0 SyntaxError: Unexpected token a in JSON at position 0 ``` ``` services: immich-server: image: altran1502/immich-server:latest container_name: "immich-server" entrypoint: ["/bin/sh", "./entrypoint.sh"] networks: immich: expose: - 3000 volumes: - "/REDACTED/Upload:/usr/src/app/upload" env_file: - /REDACTED/.env environment: - NODE_ENV=production depends_on: - immich_redis - immich_postgres restart: unless-stopped immich-web: image: altran1502/immich-web:latest container_name: "immich-web" entrypoint: ["/bin/sh", "./entrypoint.sh"] networks: immich: env_file: - /REDACTED/.env ports: - 2285:3000 restart: unless-stopped immich_redis: container_name: "immich_redis" image: redis:6.2 networks: immich: volumes: - "/REDACTED:/data" restart: unless-stopped immich_postgres: container_name: "immich_postgres" image: postgres:14 networks: immich: env_file: - /REDACTED/.env environment: POSTGRES_PASSWORD: ${IMMICH_PG_DB_PASSWORD} POSTGRES_USER: ${IMMICH_PG_DB_USERNAME} POSTGRES_DB: ${IMMICH_PG_DB_DATABASE_NAME} PG_DATA: /var/lib/postgresql/data volumes: - "/REDACTED/:/var/lib/postgresql/data" restart: unless-stopped networks: immich: driver: bridge name: "immich" internal: false ipam: driver: default config: - subnet: 172.23.25.0/24 gateway: 172.23.25.1 ``` THE env file instead is this one ``` DB_HOSTNAME=immich_postgres ################################################################################### # Database ################################################################################### DB_USERNAME=XXXXXXXXXXXXX DB_PASSWORD=XXXXXXXXXXXXX DB_DATABASE_NAME=XXXXXXXXXXXXX ################################################################################### # Upload File Config ################################################################################### UPLOAD_LOCATION=./upload ################################################################################### # JWT SECRET ################################################################################### JWT_SECRET=XXXXXXXXXXXXX ################################################################################### # MAPBOX #################################################################################### # ENABLE_MAPBOX is either true of false -> if true, you have to provide MAPBOX_KEY ENABLE_MAPBOX=true MAPBOX_KEY=XXXXXXXXXXXXX ################################################################################### # WEB ################################################################################### # This is the URL of your vm/server where you host Immich, so that the web frontend # know where can it make the request to. # For example: If your server IP address is 10.1.11.50, the environment variable will # be VITE_SERVER_ENDPOINT=http://10.1.11.50:2283 VITE_SERVER_ENDPOINT=http://IP-OF-MY-SERVER:2283 ################################################################################### # Redis ################################################################################### REDIS_HOSTNAME=immich_redis ``` Why should VITE_SERVER_ENDPOINT point to port 2283 if it is not present in the compose? In any cane here the log IMMICH SERVER ``` > immich@1.5.1 prebuild > rimraf dist > immich@1.5.1 build  > nest build > immich@1.5.1 start:prod > node dist/main [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [NestFactory] Starting Nest application... [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] TypeOrmModule dependencies initialized +169ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] JwtModule dependencies initialized +2ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] AppModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] ConfigHostModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] DiscoveryModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] ConfigModule dependencies initialized +12ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] ScheduleModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] BullModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] BullModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:09 AM LOG [InstanceLoader] ServerInfoModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] TypeOrmCoreModule dependencies initialized +301ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] TypeOrmModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] TypeOrmModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] TypeOrmModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] TypeOrmModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] TypeOrmModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] CommunicationModule dependencies initialized +4ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] ImmichJwtModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] ScheduleTasksModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] BackgroundTaskModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] ImageOptimizeModule dependencies initialized +4ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] DeviceInfoModule dependencies initialized +2ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] SharingModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] AuthModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] UserModule dependencies initialized +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [InstanceLoader] AssetModule dependencies initialized +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RoutesResolver] AppController {/}: +20ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/, GET} route +5ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RoutesResolver] UserController {/user}: +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/user, GET} route +2ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/user, POST} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/user/count, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/user, PUT} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RoutesResolver] AssetController {/asset}: +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/upload, POST} route +2ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/download, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/file, GET} route +2ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/thumbnail/:assetId, GET} route +2ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/allObjects, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/allLocation, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/searchTerm, GET} route +2ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/search, POST} route +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/:deviceId, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset/assetById/:assetId, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/asset, DELETE} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RoutesResolver] AuthController {/auth}: +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/auth/login, POST} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/auth/admin-sign-up, POST} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/auth/validateToken, POST} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RoutesResolver] DeviceInfoController {/device-info}: +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/device-info, POST} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/device-info, PATCH} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RoutesResolver] ServerInfoController {/server-info}: +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/server-info, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/server-info/ping, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/server-info/mapbox, GET} route +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/server-info/version, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RoutesResolver] SharingController {/shared}: +0ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/createAlbum, POST} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/addUsers, POST} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/addAssets, POST} route +3ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/allSharedAlbums, GET} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/:albumId, GET} route +2ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/removeAssets, DELETE} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/:albumId, DELETE} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/leaveAlbum/:albumId, DELETE} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [RouterExplorer] Mapped {/shared/updateInfo, PATCH} route +1ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [NestApplication] Nest application successfully started +41ms [Nest] 52 - 05/27/2022, 6:32:10 AM LOG [IMMICH SERVER] Running Immich Server in PRODUCTION environment ``` Here IMMICH WEB ``` > web@0.0.1 build > svelte-kit build vite v2.9.8 building for production... transforming... ✓ 687 modules transformed. rendering chunks... .svelte-kit/output/client/_app/manifest.json 3.94 KiB .svelte-kit/output/client/_app/start-7968382e.js 24.18 KiB / gzip: 8.81 KiB .svelte-kit/output/client/_app/pages/auth/login/index.svelte-aace14dc.js 16.03 KiB / gzip: 5.03 KiB .svelte-kit/output/client/_app/error.svelte-f8847189.js 1.56 KiB / gzip: 0.74 KiB .svelte-kit/output/client/_app/pages/admin/index.svelte-9879ae55.js 16.64 KiB / gzip: 5.97 KiB .svelte-kit/output/client/_app/pages/__layout.svelte-200db308.js 2.23 KiB / gzip: 1.09 KiB .svelte-kit/output/client/_app/pages/index.svelte-43ca08b8.js 2.37 KiB / gzip: 1.21 KiB .svelte-kit/output/client/_app/chunks/index-cf124ca0.js 11.54 KiB / gzip: 4.78 KiB .svelte-kit/output/client/_app/chunks/singletons-d1fb5791.js 0.05 KiB / gzip: 0.07 KiB .svelte-kit/output/client/_app/chunks/api-8119291a.js 0.45 KiB / gzip: 0.32 KiB .svelte-kit/output/client/_app/chunks/constants-f22e011b.js 0.05 KiB / gzip: 0.06 KiB .svelte-kit/output/client/_app/chunks/index-d39cff6c.js 0.76 KiB / gzip: 0.41 KiB .svelte-kit/output/client/_app/chunks/navigation-bar-cd758090.js 5.91 KiB / gzip: 2.58 KiB .svelte-kit/output/client/_app/chunks/auth-api-b3e1ef61.js 0.43 KiB / gzip: 0.16 KiB .svelte-kit/output/client/_app/chunks/navigation-0e6511d1.js 0.17 KiB / gzip: 0.15 KiB .svelte-kit/output/client/_app/assets/pages/__layout.svelte-2c48307f.css 10.35 KiB / gzip: 2.98 KiB .svelte-kit/output/client/_app/chunks/index-7389f52e.js 0.79 KiB / gzip: 0.48 KiB .svelte-kit/output/client/_app/pages/auth/register/index.svelte-ea0c4574.js 6.45 KiB / gzip: 2.55 KiB .svelte-kit/output/client/_app/pages/photos/index.svelte-88ebb3cf.js 153.84 KiB / gzip: 53.48 KiB vite v2.9.8 building SSR bundle for production... transforming... ✓ 51 modules transformed. rendering chunks... .svelte-kit/output/server/manifest.json 4.36 KiB .svelte-kit/output/server/index.js 75.63 KiB .svelte-kit/output/server/entries/endpoints/auth/login/index.ts.js 5.82 KiB .svelte-kit/output/server/entries/endpoints/auth/register/index.ts.js 0.84 KiB .svelte-kit/output/server/entries/endpoints/auth/login/update.ts.js 1.42 KiB .svelte-kit/output/server/entries/endpoints/admin/api/create-user.ts.js 0.93 KiB .svelte-kit/output/server/entries/endpoints/auth/login/api/select-admin.ts.js 1.77 KiB .svelte-kit/output/server/entries/endpoints/auth/login/api/get-users.ts.js 0.32 KiB .svelte-kit/output/server/entries/pages/__layout.svelte.js 1.21 KiB .svelte-kit/output/server/entries/fallbacks/error.svelte.js 0.72 KiB .svelte-kit/output/server/entries/pages/admin/index.svelte.js 6.69 KiB .svelte-kit/output/server/entries/pages/auth/login/index.svelte.js 1.94 KiB .svelte-kit/output/server/entries/pages/auth/register/index.svelte.js 2.86 KiB .svelte-kit/output/server/entries/pages/index.svelte.js 1.74 KiB .svelte-kit/output/server/entries/pages/photos/index.svelte.js 8.96 KiB .svelte-kit/output/server/chunks/index-6241e7e7.js 4.26 KiB .svelte-kit/output/server/chunks/constants-f22e011b.js 0.08 KiB .svelte-kit/output/server/chunks/api-75d724dc.js 0.86 KiB .svelte-kit/output/server/chunks/stores-78835596.js 0.92 KiB .svelte-kit/output/server/chunks/navigation-bar-07199bb6.js 3.41 KiB .svelte-kit/output/server/chunks/hooks-3418e942.js 1.12 KiB Run npm run preview to preview your production build locally. > Using @sveltejs/adapter-node ✔ done Listening on 0.0.0.0:3000 SyntaxError: Unexpected token a in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token a in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) SyntaxError: Unexpected token a in JSON at position 0 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) ```
Author
Owner

@alextran1502 commented on GitHub (May 27, 2022):

@mada199122 The reason you cannot access is that you removed the Nginx container. The server is served via Nginx via port 2283 which is mapped to port 80 of the Nginx container.

@alextran1502 commented on GitHub (May 27, 2022): @mada199122 The reason you cannot access is that you removed the Nginx container. The server is served via Nginx via port 2283 which is mapped to port 80 of the Nginx container.
Author
Owner

@ghost commented on GitHub (May 27, 2022):

I've VITE_SERVER_ENDPOINT=http://10.1.11.50:2283/, I get the following error

FetchError: request to https://domain.tld/%22http://10.1.11.50:2283%22/user/count failed, reason: unable to get local issuer certificate
    at ClientRequest.<anonymous> (file:///usr/src/app/build/shims-eb608bdd.js:6246:11)
    at ClientRequest.emit (node:events:527:28)
    at TLSSocket.socketErrorListener (node:_http_client:454:9)
    at TLSSocket.emit (node:events:527:28)
    at emitErrorNT (node:internal/streams/destroy:157:8)
    at emitErrorCloseNT (node:internal/streams/destroy:122:3)
    at processTicksAndRejections (node:internal/process/task_queues:83:21)
SyntaxError: Unexpected token < in JSON at position 0
    at JSON.parse (<anonymous>)
    at Proxy.<anonymous> (file:///usr/src/app/build/server/index.js:1586:29)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25)
    at async load_node (file:///usr/src/app/build/server/index.js:1605:14)
    at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20)
    at async resolve (file:///usr/src/app/build/server/index.js:2182:105)
    at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-887180e1.js:7:12)
    at async respond (file:///usr/src/app/build/server/index.js:2139:22)
    at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3)

I'm able to access the below endpoints
http://10.1.11.50:2283/server-info/ping
{"res":"pong"}
http://10.1.11.50:2283/server-info/version
{"major":1,"minor":10,"patch":0,"build":14}

@ghost commented on GitHub (May 27, 2022): I've VITE_SERVER_ENDPOINT=http://10.1.11.50:2283/, I get the following error ``` FetchError: request to https://domain.tld/%22http://10.1.11.50:2283%22/user/count failed, reason: unable to get local issuer certificate at ClientRequest.<anonymous> (file:///usr/src/app/build/shims-eb608bdd.js:6246:11) at ClientRequest.emit (node:events:527:28) at TLSSocket.socketErrorListener (node:_http_client:454:9) at TLSSocket.emit (node:events:527:28) at emitErrorNT (node:internal/streams/destroy:157:8) at emitErrorCloseNT (node:internal/streams/destroy:122:3) at processTicksAndRejections (node:internal/process/task_queues:83:21) SyntaxError: Unexpected token < in JSON at position 0 at JSON.parse (<anonymous>) at Proxy.<anonymous> (file:///usr/src/app/build/server/index.js:1586:29) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async load (file:///usr/src/app/build/server/entries/pages/index.svelte.js:6:25) at async load_node (file:///usr/src/app/build/server/index.js:1605:14) at async respond$1 (file:///usr/src/app/build/server/index.js:1844:20) at async resolve (file:///usr/src/app/build/server/index.js:2182:105) at async Object.handle (file:///usr/src/app/build/server/chunks/hooks-887180e1.js:7:12) at async respond (file:///usr/src/app/build/server/index.js:2139:22) at async Array.ssr (file:///usr/src/app/build/handler-edaaddc2.js:841:3) ``` I'm able to access the below endpoints http://10.1.11.50:2283/server-info/ping `{"res":"pong"}` http://10.1.11.50:2283/server-info/version `{"major":1,"minor":10,"patch":0,"build":14}`
Author
Owner

@alextran1502 commented on GitHub (May 27, 2022):

@badlandspray Are you using your own reverse proxy setup? Can you try to fix the VITE_SERVER_ENDPOINT by removing the forward slash at the end of the IP address, so http://10.1.11.50:2283 instead of http://10.1.11.50:2283/?

After fixing that, can you access http://10.1.11.50:2285?

@alextran1502 commented on GitHub (May 27, 2022): @badlandspray Are you using your own reverse proxy setup? Can you try to fix the `VITE_SERVER_ENDPOINT` by removing the forward slash at the end of the IP address, so `http://10.1.11.50:2283` instead of `http://10.1.11.50:2283/`? After fixing that, can you access `http://10.1.11.50:2285`?
Author
Owner

@mada199122 commented on GitHub (May 28, 2022):

@mada199122 The reason you cannot access is that you removed the Nginx container. The server is served via Nginx via port 2283 which is mapped to port 80 of the Nginx container.

Ok thank you.
Now I've added the Nginx container to the compose

  immich_nginx_proxy:
    container_name: immich_nginx_proxy
    image: nginx:latest
    networks:
      immich:
    volumes:
      - "path_to_the_folder:/etc/nginx/conf.d:rw"
    # logging:
    #   driver: none
    ports:
      - 2283:80
      - 2284:443
    depends_on:
      - immich-server
    restart: unless-stopped

And now I have this error:

500
Unexpected token b in JSON at position 4
SyntaxError: Unexpected token b in JSON at position 4

The log of the web container and the server container are exactly the same as the attached one of my previous post.

But now I'm able to get this
http://X.X.X.X:2283/server-info/ping
{"res":"pong"}
http://X.X.X.X:2283/server-info/version
{"major":1,"minor":10,"patch":0,"build":14}

The log NGINX is the following one

/docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
/docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
/docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh
10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist
/docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh
/docker-entrypoint.sh: Configuration complete; ready for start up
2022/05/28 06:44:05 [emerg] 1#1: host not found in upstream "immich-server" in /etc/nginx/conf.d/nginx.conf:43
nginx: [emerg] host not found in upstream "immich-server" in /etc/nginx/conf.d/nginx.conf:43
/docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
/docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
/docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh
10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist
/docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh
/docker-entrypoint.sh: Configuration complete; ready for start up
2022/05/28 06:44:06 [notice] 1#1: using the "epoll" event method
2022/05/28 06:44:06 [notice] 1#1: nginx/1.21.6
2022/05/28 06:44:06 [notice] 1#1: built by gcc 10.2.1 20210110 (Debian 10.2.1-6) 
2022/05/28 06:44:06 [notice] 1#1: OS: Linux 4.4.180+
2022/05/28 06:44:06 [notice] 1#1: getrlimit(RLIMIT_NOFILE): 1048576:1048576
2022/05/28 06:44:06 [notice] 1#1: start worker processes
2022/05/28 06:44:06 [notice] 1#1: start worker process 23
2022/05/28 06:44:06 [notice] 1#1: start worker process 24
2022/05/28 06:44:06 [notice] 1#1: start worker process 25
2022/05/28 06:44:06 [notice] 1#1: start worker process 26
@mada199122 commented on GitHub (May 28, 2022): > @mada199122 The reason you cannot access is that you removed the Nginx container. The server is served via Nginx via port 2283 which is mapped to port 80 of the Nginx container. Ok thank you. Now I've added the Nginx container to the compose ``` immich_nginx_proxy: container_name: immich_nginx_proxy image: nginx:latest networks: immich: volumes: - "path_to_the_folder:/etc/nginx/conf.d:rw" # logging: # driver: none ports: - 2283:80 - 2284:443 depends_on: - immich-server restart: unless-stopped ``` And now I have this error: ``` 500 Unexpected token b in JSON at position 4 SyntaxError: Unexpected token b in JSON at position 4 ``` The log of the web container and the server container are exactly the same as the attached one of my previous post. But now I'm able to get this http://X.X.X.X:2283/server-info/ping {"res":"pong"} http://X.X.X.X:2283/server-info/version {"major":1,"minor":10,"patch":0,"build":14} The log NGINX is the following one ``` /docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration /docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/ /docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh 10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist /docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh /docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh /docker-entrypoint.sh: Configuration complete; ready for start up 2022/05/28 06:44:05 [emerg] 1#1: host not found in upstream "immich-server" in /etc/nginx/conf.d/nginx.conf:43 nginx: [emerg] host not found in upstream "immich-server" in /etc/nginx/conf.d/nginx.conf:43 /docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration /docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/ /docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh 10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist /docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh /docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh /docker-entrypoint.sh: Configuration complete; ready for start up 2022/05/28 06:44:06 [notice] 1#1: using the "epoll" event method 2022/05/28 06:44:06 [notice] 1#1: nginx/1.21.6 2022/05/28 06:44:06 [notice] 1#1: built by gcc 10.2.1 20210110 (Debian 10.2.1-6) 2022/05/28 06:44:06 [notice] 1#1: OS: Linux 4.4.180+ 2022/05/28 06:44:06 [notice] 1#1: getrlimit(RLIMIT_NOFILE): 1048576:1048576 2022/05/28 06:44:06 [notice] 1#1: start worker processes 2022/05/28 06:44:06 [notice] 1#1: start worker process 23 2022/05/28 06:44:06 [notice] 1#1: start worker process 24 2022/05/28 06:44:06 [notice] 1#1: start worker process 25 2022/05/28 06:44:06 [notice] 1#1: start worker process 26 ```
Author
Owner

@alextran1502 commented on GitHub (May 28, 2022):

@mada199122 there is the configuration file of Nginx in the 'docker' folder of the repo that you have to include in your setup.

@alextran1502 commented on GitHub (May 28, 2022): @mada199122 there is the configuration file of Nginx in the 'docker' folder of the repo that you have to include in your setup.
Author
Owner

@ghost commented on GitHub (May 28, 2022):

@alextran1502 Now, I'm able to access the :2285and I created an account, upon visting /admin I get the below error:'

500

NetworkError when attempting to fetch resource.

h@https://domain.tld/_app/chunks/api-ccfa9cbd.js:1:285
p@https://domain.tld/_app/chunks/api-ccfa9cbd.js:1:401
Ut@https://domain.tld/_app/pages/admin/index.svelte-52a2a867.js:1:16446
Q@https://domain.tld/_app/start-179688cd.js:1:17679
Ne@https://domain.tld/_app/start-179688cd.js:1:18906

Console errors

Uncaught (in promise) TypeError: NetworkError when attempting to fetch resource.
    h https://domain.tld/_app/chunks/api-ccfa9cbd.js:1
    p https://domain.tld/_app/chunks/api-ccfa9cbd.js:1
    y https://domain.tld/_app/pages/__layout.svelte-8a85a46c.js:3
Blocked loading mixed active content “http://10.1.11.50:2283/asset”

Uncaught (in promise) TypeError: NetworkError when attempting to fetch resource.
    h https://domain.tld/_app/chunks/api-ccfa9cbd.js:1
    p https://domain.tld/_app/chunks/api-ccfa9cbd.js:1
    mD https://domain.tld/_app/pages/photos/index.svelte-5e7225f8.js:37
    tE https://domain.tld/_app/pages/photos/index.svelte-5e7225f8.js:37
    U https://domain.tld/_app/chunks/index-cf124ca0.js:1
    Ot https://domain.tld/_app/chunks/index-cf124ca0.js:4
    I https://domain.tld/_app/chunks/index-cf124ca0.js:4

Blocked loading mixed active content “http://10.1.11.50:2283/user”

Blocked loading mixed active content “http://10.1.11.50:2283/server-info/ping”

Uncaught (in promise) TypeError: NetworkError when attempting to fetch resource.
    h https://domain.tld/_app/chunks/api-ccfa9cbd.js:1
    p https://domain.tld/_app/chunks/api-ccfa9cbd.js:1
    y https://domain.tld/_app/pages/__layout.svelte-8a85a46c.js:3

Blocked loading mixed active content “http://10.1.11.50:2283/server-info/ping”
@ghost commented on GitHub (May 28, 2022): @alextran1502 Now, I'm able to access the `:2285`and I created an account, upon visting `/admin` I get the below error:' ``` 500 NetworkError when attempting to fetch resource. h@https://domain.tld/_app/chunks/api-ccfa9cbd.js:1:285 p@https://domain.tld/_app/chunks/api-ccfa9cbd.js:1:401 Ut@https://domain.tld/_app/pages/admin/index.svelte-52a2a867.js:1:16446 Q@https://domain.tld/_app/start-179688cd.js:1:17679 Ne@https://domain.tld/_app/start-179688cd.js:1:18906 ``` Console errors ``` Uncaught (in promise) TypeError: NetworkError when attempting to fetch resource. h https://domain.tld/_app/chunks/api-ccfa9cbd.js:1 p https://domain.tld/_app/chunks/api-ccfa9cbd.js:1 y https://domain.tld/_app/pages/__layout.svelte-8a85a46c.js:3 Blocked loading mixed active content “http://10.1.11.50:2283/asset” Uncaught (in promise) TypeError: NetworkError when attempting to fetch resource. h https://domain.tld/_app/chunks/api-ccfa9cbd.js:1 p https://domain.tld/_app/chunks/api-ccfa9cbd.js:1 mD https://domain.tld/_app/pages/photos/index.svelte-5e7225f8.js:37 tE https://domain.tld/_app/pages/photos/index.svelte-5e7225f8.js:37 U https://domain.tld/_app/chunks/index-cf124ca0.js:1 Ot https://domain.tld/_app/chunks/index-cf124ca0.js:4 I https://domain.tld/_app/chunks/index-cf124ca0.js:4 Blocked loading mixed active content “http://10.1.11.50:2283/user” Blocked loading mixed active content “http://10.1.11.50:2283/server-info/ping” Uncaught (in promise) TypeError: NetworkError when attempting to fetch resource. h https://domain.tld/_app/chunks/api-ccfa9cbd.js:1 p https://domain.tld/_app/chunks/api-ccfa9cbd.js:1 y https://domain.tld/_app/pages/__layout.svelte-8a85a46c.js:3 Blocked loading mixed active content “http://10.1.11.50:2283/server-info/ping” ```
Author
Owner

@alextran1502 commented on GitHub (May 28, 2022):

@badlandspray is this from your access through the local IP or from the public domain that is proxied to the private IP?

@alextran1502 commented on GitHub (May 28, 2022): @badlandspray is this from your access through the local IP or from the public domain that is proxied to the private IP?
Author
Owner

@ghost commented on GitHub (May 28, 2022):

Local IP. I'm using caddy. I've tried setting VITE_SERVER_ENDPOINT=http://immich-server:3000.as well. Must be something wrong on my side.

@ghost commented on GitHub (May 28, 2022): Local IP. I'm using caddy. I've tried setting `VITE_SERVER_ENDPOINT=http://immich-server:3000`.as well. Must be something wrong on my side.
Author
Owner

@alextran1502 commented on GitHub (May 29, 2022):

@badlandspray If you start fresh from the beginning and follow the readme file, do you have any problems?

@alextran1502 commented on GitHub (May 29, 2022): @badlandspray If you start fresh from the beginning and follow the readme file, do you have any problems?
Author
Owner

@mada199122 commented on GitHub (May 29, 2022):

@mada199122 there is the configuration file of Nginx in the 'docker' folder of the repo that you have to include in your setup.

Yes of course I've already put that file in the mount volume of nginx container

Screenshot 2022-05-29 at 16 18 30

But It seams from the log that nginx container is asking for a default configuration file

from this line of the log

10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist

@mada199122 commented on GitHub (May 29, 2022): > @mada199122 there is the configuration file of Nginx in the 'docker' folder of the repo that you have to include in your setup. Yes of course I've already put that file in the mount volume of nginx container ![Screenshot 2022-05-29 at 16 18 30](https://user-images.githubusercontent.com/61902329/170873877-1e9c1010-546b-417f-81c4-cbbdf8bd2e98.jpg) But It seams from the log that nginx container is asking for a default configuration file from this line of the log `10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist`
Author
Owner

@alextran1502 commented on GitHub (May 29, 2022):

@mada199122 This is the location that the Nginx container is looking for the config file

Screen Shot 2022-05-29 at 09 21 19

If you look at the docker folder in the repo, the nginx.conf is put in the folder settings/nginx-conf. Perhaps you have to create 2 folders settings > nginx-conf then put the config file in there.

I am not sure which tool you use to run the application so I don't have more information to fully provide support.

@alextran1502 commented on GitHub (May 29, 2022): @mada199122 This is the location that the Nginx container is looking for the config file <img width="381" alt="Screen Shot 2022-05-29 at 09 21 19" src="https://user-images.githubusercontent.com/27055614/170874002-5d19b39e-a06e-45a6-9a67-9c8fbaa8d9b1.png"> If you look at the `docker` folder in the repo, the `nginx.conf` is put in the folder `settings/nginx-conf`. Perhaps you have to create 2 folders `settings > nginx-conf` then put the config file in there. I am not sure which tool you use to run the application so I don't have more information to fully provide support.
Author
Owner

@mada199122 commented on GitHub (May 29, 2022):

But in docker compose the left path should be whatever I want in my host machine that it will be translated by docker to the path at the right side inside the container.
it shouldn't matter...

Now I've modified the compose to include the two folder as suggeste but nothing has changed:(

Screenshot 2022-05-29 at 16 18 30

  immich_nginx_proxy:
    container_name: immich_nginx_proxy
    image: nginx:latest
    networks:
      immich:
    volumes:
      - "/volume1/docker/Immich/nginx/settings/nginx-conf:/etc/nginx/conf.d"
    # logging:
    #   driver: none
    ports:
      - 2283:80
      - 2284:443
    depends_on:
      - immich-server
    restart: unless-stopped
@mada199122 commented on GitHub (May 29, 2022): But in docker compose the left path should be whatever I want in my host machine that it will be translated by docker to the path at the right side inside the container. it shouldn't matter... Now I've modified the compose to include the two folder as suggeste but nothing has changed:( ![Screenshot 2022-05-29 at 16 18 30](https://user-images.githubusercontent.com/61902329/170874838-2ed17b6f-5229-410f-9b68-78d66b16189b.jpg) ``` immich_nginx_proxy: container_name: immich_nginx_proxy image: nginx:latest networks: immich: volumes: - "/volume1/docker/Immich/nginx/settings/nginx-conf:/etc/nginx/conf.d" # logging: # driver: none ports: - 2283:80 - 2284:443 depends_on: - immich-server restart: unless-stopped ```
Author
Owner

@alextran1502 commented on GitHub (May 29, 2022):

@mada199122 I am not sure if you have uploaded the correct image but it seems to not the correct path you showed in the docker-compose file

@alextran1502 commented on GitHub (May 29, 2022): @mada199122 I am not sure if you have uploaded the correct image but it seems to not the correct path you showed in the docker-compose file
Author
Owner

@mada199122 commented on GitHub (May 29, 2022):

no it is correct, /volume1 is not shown in the GUI of Synology NAS

I've attached a screenshot from the shell

Screenshot 2022-05-29 at 16 44 03

@mada199122 commented on GitHub (May 29, 2022): no it is correct, /volume1 is not shown in the GUI of Synology NAS I've attached a screenshot from the shell ![Screenshot 2022-05-29 at 16 44 03](https://user-images.githubusercontent.com/61902329/170875323-730d98f2-cdd9-4f6c-8309-70aa5ec1d3d5.jpg)
Author
Owner

@alextran1502 commented on GitHub (May 29, 2022):

@mada199122 Let's try two things

  1. Can you remove the double quote to see if it make the different, so /volume1/docker/Immich/nginx/settings/nginx-conf:/etc/nginx/conf.d
  2. If the above doesn't work, can you commented out the Nginx container and expose the port in the immich-server container by adding
ports:
  - 2283:3000
@alextran1502 commented on GitHub (May 29, 2022): @mada199122 Let's try two things 1. Can you remove the double quote to see if it make the different, so `/volume1/docker/Immich/nginx/settings/nginx-conf:/etc/nginx/conf.d` 2. If the above doesn't work, can you commented out the Nginx container and expose the port in the `immich-server` container by adding ``` ports: - 2283:3000 ```
Author
Owner

@mada199122 commented on GitHub (May 29, 2022):

tried both but nothing... always the same error..

@mada199122 commented on GitHub (May 29, 2022): tried both but nothing... always the same error..
Author
Owner

@mada199122 commented on GitHub (May 29, 2022):

At the port 2283 I get this now

Screenshot 2022-05-29 at 17 37 03

@mada199122 commented on GitHub (May 29, 2022): At the port 2283 I get this now ![Screenshot 2022-05-29 at 17 37 03](https://user-images.githubusercontent.com/61902329/170877954-f1f78d3b-4bc3-4f10-8d2d-0ace030acc30.jpg)
Author
Owner

@alextran1502 commented on GitHub (May 29, 2022):

@mada199122 Can you post your docker-compose file again? Did you perform docker-compose down and docker-compose up after you updated the file content?

@alextran1502 commented on GitHub (May 29, 2022): @mada199122 Can you post your `docker-compose` file again? Did you perform `docker-compose down` and `docker-compose up` after you updated the file content?
Author
Owner

@mada199122 commented on GitHub (May 29, 2022):

Yes I've removed completely all the container and re-created

This is my actual compose

services:
  immich-server:
    image: altran1502/immich-server:latest
    container_name: "immich-server"
    entrypoint: ["/bin/sh", "./entrypoint.sh"]
    networks:
      immich:
    volumes:
      - /volume1/docker/Immich/Upload:/usr/src/app/upload
    env_file:
      - /volume1/docker/Immich/Immich.env
    expose:
      - 3000
    environment:
      - NODE_ENV=production
    depends_on:
      - immich_redis
      - immich_postgres
    restart: unless-stopped

  immich-web:
    image: altran1502/immich-web:latest
    container_name: "immich-web"
    entrypoint: ["/bin/sh", "./entrypoint.sh"]
    networks:
      immich:
    env_file:
      - /volume1/docker/Immich/Immich.env
    ports:
      - 2285:3000
    restart: unless-stopped

  immich_redis:
    container_name: "immich_redis"
    image: redis:6.2
    networks:
      immich:
    volumes:
      - /volume1/docker/Immich/Redis:/data

  immich_postgres:
    container_name: "immich_postgres"
    image: postgres:14
    networks:
      immich:
    env_file:
      - /volume1/docker/Immich/Immich.env
    environment:
      POSTGRES_PASSWORD: ${IMMICH_PG_DB_PASSWORD}
      POSTGRES_USER: ${IMMICH_PG_DB_USERNAME}
      POSTGRES_DB: ${IMMICH_PG_DB_DATABASE_NAME}
      PG_DATA: /var/lib/postgresql/data
    volumes:
      - /volume1/docker/Immich/Database:/var/lib/postgresql/data
    restart: unless-stopped


  immich_nginx_proxy:
    container_name: immich_nginx_proxy
    image: nginx:latest
    networks:
      immich:
    volumes:
      - /volume1/docker/Immich/nginx/settings/nginx-conf:/etc/nginx/conf.d
    # logging:
    #   driver: none
    ports:
      - 2283:80
      - 2284:443
    depends_on:
      - immich-server
    restart: unless-stopped


networks:

  immich:
    driver: bridge
    name: "immich"
    internal: false
    ipam:
      driver: default
      config:
        - subnet: 172.23.25.0/24
          gateway: 172.23.25.1
@mada199122 commented on GitHub (May 29, 2022): Yes I've removed completely all the container and re-created This is my actual compose ``` services: immich-server: image: altran1502/immich-server:latest container_name: "immich-server" entrypoint: ["/bin/sh", "./entrypoint.sh"] networks: immich: volumes: - /volume1/docker/Immich/Upload:/usr/src/app/upload env_file: - /volume1/docker/Immich/Immich.env expose: - 3000 environment: - NODE_ENV=production depends_on: - immich_redis - immich_postgres restart: unless-stopped immich-web: image: altran1502/immich-web:latest container_name: "immich-web" entrypoint: ["/bin/sh", "./entrypoint.sh"] networks: immich: env_file: - /volume1/docker/Immich/Immich.env ports: - 2285:3000 restart: unless-stopped immich_redis: container_name: "immich_redis" image: redis:6.2 networks: immich: volumes: - /volume1/docker/Immich/Redis:/data immich_postgres: container_name: "immich_postgres" image: postgres:14 networks: immich: env_file: - /volume1/docker/Immich/Immich.env environment: POSTGRES_PASSWORD: ${IMMICH_PG_DB_PASSWORD} POSTGRES_USER: ${IMMICH_PG_DB_USERNAME} POSTGRES_DB: ${IMMICH_PG_DB_DATABASE_NAME} PG_DATA: /var/lib/postgresql/data volumes: - /volume1/docker/Immich/Database:/var/lib/postgresql/data restart: unless-stopped immich_nginx_proxy: container_name: immich_nginx_proxy image: nginx:latest networks: immich: volumes: - /volume1/docker/Immich/nginx/settings/nginx-conf:/etc/nginx/conf.d # logging: # driver: none ports: - 2283:80 - 2284:443 depends_on: - immich-server restart: unless-stopped networks: immich: driver: bridge name: "immich" internal: false ipam: driver: default config: - subnet: 172.23.25.0/24 gateway: 172.23.25.1 ```
Author
Owner

@alextran1502 commented on GitHub (May 30, 2022):

@mada199122 Before changing the content of the docker-compose, if you keep the same content and follow the direction in the readme file, with placing the nginx.conf at the correct location, can you test this scenario first? Then gradually change each container to your settings to catch errors incrementally

@alextran1502 commented on GitHub (May 30, 2022): @mada199122 Before changing the content of the docker-compose, if you keep the same content and follow the direction in the readme file, with placing the `nginx.conf` at the correct location, can you test this scenario first? Then gradually change each container to your settings to catch errors incrementally
Author
Owner

@mada199122 commented on GitHub (May 30, 2022):

@mada199122 Before changing the content of the docker-compose, if you keep the same content and follow the direction in the readme file, with placing the nginx.conf at the correct location, can you test this scenario first? Then gradually change each container to your settings to catch errors incrementally

sorry I my previous post I copied the wrong NGINX compose, now I correct...

nginx.conf is in the correct location mapped in docker compose...

./settings/nginx-conf:/etc/nginx/conf.d is exactly equivalent than mine...
sorry but I cannot understand the difference been that string a mapping path left to right

Could you explain me what is causing this of this error please?

Unexpected token b in JSON at position 4
SyntaxError: Unexpected token b in JSON at position 4

So I can try to understand better what is wrong.

from my limited point of view it seams that immich-web is not able to talk to nginx if it speaks to nginx or to the server...
because from http://IP:2283/server-info/ping I'm getting the answer "pong", so nginx and immich-server containers are talking each other...

In immich-web log I see this

SyntaxError: Unexpected token b in JSON at position 4
at JSON.parse (<anonymous>)
at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73)
at respond (file:///usr/src/app/build/server/index.js:2139:42)
@mada199122 commented on GitHub (May 30, 2022): > @mada199122 Before changing the content of the docker-compose, if you keep the same content and follow the direction in the readme file, with placing the `nginx.conf` at the correct location, can you test this scenario first? Then gradually change each container to your settings to catch errors incrementally sorry I my previous post I copied the wrong NGINX compose, now I correct... nginx.conf is in the correct location mapped in docker compose... `./settings/nginx-conf:/etc/nginx/conf.d` is exactly equivalent than mine... sorry but I cannot understand the difference been that string a mapping path left to right Could you explain me what is causing this of this error please? ``` Unexpected token b in JSON at position 4 SyntaxError: Unexpected token b in JSON at position 4 ``` So I can try to understand better what is wrong. from my limited point of view it seams that immich-web is not able to talk to nginx if it speaks to nginx or to the server... because from `http://IP:2283/server-info/ping` I'm getting the answer "pong", so nginx and immich-server containers are talking each other... In immich-web log I see this ``` SyntaxError: Unexpected token b in JSON at position 4 at JSON.parse (<anonymous>) at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73) at respond (file:///usr/src/app/build/server/index.js:2139:42) ```
Author
Owner

@wavesswe commented on GitHub (May 31, 2022):

/server-info/ping

I get 404 Not Found, before i tried i ran "docker-compose pull immich-web && docker-compose pull immich-server" again.

I can read the http://192.168.x.xx:2285/auth/login page but the http://192.168.x.xx:2285 page still throws the same error

@wavesswe commented on GitHub (May 31, 2022): > /server-info/ping I get 404 Not Found, before i tried i ran "docker-compose pull immich-web && docker-compose pull immich-server" again. I can read the http://192.168.x.xx:2285/auth/login page but the http://192.168.x.xx:2285 page still throws the same error
Author
Owner

@alextran1502 commented on GitHub (May 31, 2022):

@wavesswe Can you try to clear the session in the cookie from the web dev tool?

@alextran1502 commented on GitHub (May 31, 2022): @wavesswe Can you try to clear the `session` in the cookie from the web dev tool?
Author
Owner

@alextran1502 commented on GitHub (May 31, 2022):

@mada199122 Before changing the content of the docker-compose, if you keep the same content and follow the direction in the readme file, with placing the nginx.conf at the correct location, can you test this scenario first? Then gradually change each container to your settings to catch errors incrementally

sorry I my previous post I copied the wrong NGINX compose, now I correct...

nginx.conf is in the correct location mapped in docker compose...

./settings/nginx-conf:/etc/nginx/conf.d is exactly equivalent than mine... sorry but I cannot understand the difference been that string a mapping path left to right

Could you explain me what is causing this of this error please?

Unexpected token b in JSON at position 4
SyntaxError: Unexpected token b in JSON at position 4

So I can try to understand better what is wrong.

from my limited point of view it seams that immich-web is not able to talk to nginx if it speaks to nginx or to the server... because from http://IP:2283/server-info/ping I'm getting the answer "pong", so nginx and immich-server containers are talking each other...

In immich-web log I see this

SyntaxError: Unexpected token b in JSON at position 4
at JSON.parse (<anonymous>)
at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73)
at respond (file:///usr/src/app/build/server/index.js:2139:42)

I am not sure why you are seeing that either, have you tried clearing the session in the cookie of the browser dev tool?

image

@alextran1502 commented on GitHub (May 31, 2022): > > @mada199122 Before changing the content of the docker-compose, if you keep the same content and follow the direction in the readme file, with placing the `nginx.conf` at the correct location, can you test this scenario first? Then gradually change each container to your settings to catch errors incrementally > > sorry I my previous post I copied the wrong NGINX compose, now I correct... > > nginx.conf is in the correct location mapped in docker compose... > > `./settings/nginx-conf:/etc/nginx/conf.d` is exactly equivalent than mine... sorry but I cannot understand the difference been that string a mapping path left to right > > Could you explain me what is causing this of this error please? > > ``` > Unexpected token b in JSON at position 4 > SyntaxError: Unexpected token b in JSON at position 4 > ``` > > So I can try to understand better what is wrong. > > from my limited point of view it seams that immich-web is not able to talk to nginx if it speaks to nginx or to the server... because from `http://IP:2283/server-info/ping` I'm getting the answer "pong", so nginx and immich-server containers are talking each other... > > In immich-web log I see this > > ``` > SyntaxError: Unexpected token b in JSON at position 4 > at JSON.parse (<anonymous>) > at Object.handle (file:///usr/src/app/build/server/chunks/hooks-3418e942.js:9:73) > at respond (file:///usr/src/app/build/server/index.js:2139:42) > ``` I am not sure why you are seeing that either, have you tried clearing the session in the cookie of the browser dev tool? ![image](https://user-images.githubusercontent.com/27055614/171066332-a33f70fd-de31-4f63-b887-adb08f7232ad.png)
Author
Owner

@mada199122 commented on GitHub (May 31, 2022):

Finally I got it working...
I don't know actually what I've done... But yesterday after many failed attempts I shut all the 4 containers down...
Now to try to clear the cookie session as you suggested I started the containers and magically now works...

I have two clues...
yesterday I've change the name of the nginx container, before I was using "immich_nginx_proxy" now I changed to the default one you use in your compose.

this is my nginx compose now

  nginx:
    container_name: proxy_nginx
    image: nginx:latest
    networks:
      immich:
    volumes:
      - /volume1/docker/Immich/nginx/settings/nginx-conf:/etc/nginx/conf.d/
    # logging:
    #   driver: none
    ports:
      - 2283:80
      - 2284:443
    depends_on:
      - immich-server
    restart: unless-stopped

In the code of the container immich-web, have you hardcoded the address of the nginx container by its name of the container?

The second clue is that the last days I was using Safari browser during all the attempts, today accidentally I've tried to access immich-web with Firefox...
Now I don't know what to think... it seams it works on both browser...

@mada199122 commented on GitHub (May 31, 2022): Finally I got it working... I don't know actually what I've done... But yesterday after many failed attempts I shut all the 4 containers down... Now to try to clear the cookie session as you suggested I started the containers and magically now works... I have two clues... yesterday I've change the name of the nginx container, before I was using "**immich_nginx_proxy**" now I changed to the default one you use in your compose. this is my nginx compose now ``` nginx: container_name: proxy_nginx image: nginx:latest networks: immich: volumes: - /volume1/docker/Immich/nginx/settings/nginx-conf:/etc/nginx/conf.d/ # logging: # driver: none ports: - 2283:80 - 2284:443 depends_on: - immich-server restart: unless-stopped ``` In the code of the container immich-web, have you hardcoded the address of the nginx container by its name of the container? The second clue is that the last days I was using Safari browser during all the attempts, today accidentally I've tried to access immich-web with Firefox... Now I don't know what to think... it seams it works on both browser...
Author
Owner

@alextran1502 commented on GitHub (Jun 1, 2022):

@mada199122 I am glad it is working now for you. Perhaps you didn't shut down the container before when you perform the docker-compose pull step? Probably shutting it down perform a complete reset and register the most recent code change for the application

@alextran1502 commented on GitHub (Jun 1, 2022): @mada199122 I am glad it is working now for you. Perhaps you didn't shut down the container before when you perform the `docker-compose pull` step? Probably shutting it down perform a complete reset and register the most recent code change for the application
Author
Owner

@alextran1502 commented on GitHub (Jun 12, 2022):

Closing this issue as this is mostly a configuration problem from the user's side and it has expanded into an issue with scattered information about a different topic.

Please visit the Discord channel for additional help https://discord.gg/rxnyVTXGbM

@alextran1502 commented on GitHub (Jun 12, 2022): Closing this issue as this is mostly a configuration problem from the user's side and it has expanded into an issue with scattered information about a different topic. Please visit the Discord channel for additional help https://discord.gg/rxnyVTXGbM
Author
Owner

@spupuz commented on GitHub (Oct 11, 2022):

it works.

Il giorno lun 23 mag 2022 alle ore 15:58 Alex @.***> ha
scritto:

Can you help me check this endpoint?
http://your-ip:2283/server-info/version


Reply to this email directly, view it on GitHub
https://github.com/alextran1502/immich/issues/170#issuecomment-1134713895,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AANELQFTIZTRVZ6XNFORM63VLOFHBANCNFSM5WSRMT3Q
.
You are receiving this because you were mentioned.Message ID:
@.***>

@spupuz commented on GitHub (Oct 11, 2022): it works. Il giorno lun 23 mag 2022 alle ore 15:58 Alex ***@***.***> ha scritto: > Can you help me check this endpoint? > http://your-ip:2283/server-info/version > > — > Reply to this email directly, view it on GitHub > <https://github.com/alextran1502/immich/issues/170#issuecomment-1134713895>, > or unsubscribe > <https://github.com/notifications/unsubscribe-auth/AANELQFTIZTRVZ6XNFORM63VLOFHBANCNFSM5WSRMT3Q> > . > You are receiving this because you were mentioned.Message ID: > ***@***.***> >
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#71