Closed Heavensong89 closed 2 months ago
Are you sure that the PUBLIC_APP_URL
is really set to https://id.example.com
? You can verify it with
docker exec pocket-id env | grep PUBLIC_APP_URL
Are you sure that the
PUBLIC_APP_URL
is really set tohttps://id.example.com
? You can verify it withdocker exec pocket-id env | grep PUBLIC_APP_URL
Yes. It’s set in Unraid Docker UI’s variables, and that command returns the URL that i set it as.
Okay thanks, does your domain (id.example.com) point to the local IP 192.168.7.127?
Same problem here. docker exec pocket-id env | grep PUBLIC_APP_URL Is give my the good url. Swag is pointing to 192.168.xx.xx:3000 and same on Cloudflare tunnel mod
Yeah the issue probably occurs because 192.168.xx.xx
isn't accessible inside the docker container. I've created a potential fix. Would you mind to test the stonith404/pocket-id:development
image?
pocket-id:development
Can now load but looks like images are broken and get error occurred alert when clicking continue
Could you share the container logs?
Could you share the container logs?
Listening on 0.0.0.0:3000
[GIN] 2024/08/17 - 08:56:48 | 401 | 26.16µs | ::1 | GET "/api/users/me"
[GIN] 2024/08/17 - 08:56:48 | 401 | 42.02µs | ::1 | GET "/api/users/me"
[GIN] 2024/08/17 - 08:56:48 | 200 | 206.016µs | ::1 | GET "/api/application-configuration"
[GIN] 2024/08/17 - 08:56:48 | 200 | 223.204µs | ::1 | GET "/api/application-configuration"
[GIN] 2024/08/17 - 08:56:48 | 401 | 16.753µs | ::1 | GET "/api/users/me"
[GIN] 2024/08/17 - 08:56:48 | 401 | 35.199µs | ::1 | GET "/api/users/me"
[GIN] 2024/08/17 - 08:56:48 | 200 | 188.891µs | ::1 | GET "/api/application-configuration"
[GIN] 2024/08/17 - 08:56:48 | 200 | 250.385µs | ::1 | GET "/api/application-configuration"
[GIN] 2024/08/17 - 08:56:48 | 401 | 12.246µs | ::1 | GET "/api/users/me"
[GIN] 2024/08/17 - 08:56:48 | 401 | 23.134µs | ::1 | GET "/api/users/me"
SvelteKitError: Not found: /api/application-configuration/logo
at resolve2 (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5273:18)
at resolve (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5106:34)
at Object.handle (file:///app/frontend/build/server/chunks/hooks.server-BZMsLR3h.js:41:26)
at respond (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5104:43) {
status: 404,
text: 'Not Found'
}
[GIN] 2024/08/17 - 08:56:48 | 200 | 129.898µs | ::1 | GET "/api/application-configuration"
[GIN] 2024/08/17 - 08:56:48 | 200 | 138.049µs | ::1 | GET "/api/application-configuration"
SvelteKitError: Not found: /api/application-configuration/background-image
at resolve2 (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5273:18)
at resolve (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5106:34)
at Object.handle (file:///app/frontend/build/server/chunks/hooks.server-BZMsLR3h.js:41:26)
at respond (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5104:43) {
status: 404,
text: 'Not Found'
}
[GIN] 2024/08/17 - 08:56:50 | 401 | 20.973µs | ::1 | GET "/api/users/me"
[GIN] 2024/08/17 - 08:56:50 | 401 | 56.818µs | ::1 | GET "/api/users/me"
[GIN] 2024/08/17 - 08:56:50 | 200 | 190.647µs | ::1 | GET "/api/application-configuration"
[GIN] 2024/08/17 - 08:56:50 | 200 | 211.641µs | ::1 | GET "/api/application-configuration"
SvelteKitError: Not found: /api/one-time-access-token/setup
at resolve2 (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5273:18)
at resolve (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5106:34)
at Object.handle (file:///app/frontend/build/server/chunks/hooks.server-BZMsLR3h.js:41:26)
at respond (file:///app/frontend/build/server/chunks/index-CjGFhKNr.js:5104:43) {
status: 404,
text: 'Not Found'
}
Oh, I think this is an issue of the Unraid template, I'm not using Unraid because of that the template isn't made by me. Can you try to change the port of the application in the template to 80
instead of 3000
?
The frontend runs on port 3000
, the backend on 8080
and the reverse proxy on 80
. You have to access Pocket ID over the reverse proxy because if you directly access the frontend, the path /api/**
isn't found.
Oh, I think this is an issue of the Unraid template, I'm not using Unraid because of that the template isn't made by me. Can you try to change the port of the application in the template to
80
instead of3000
?The frontend runs on port
3000
, the backend on8080
and the reverse proxy on80
. You have to access Pocket ID over the reverse proxy because if you directly access the frontend, the path/api/**
isn't found.
So should the PORT environment variable be set to 80 for the frontend? Or still keep frontend as 3000 but also expose/reverse proxy port 80?
Edit: Confirmed, leave PORT as 3000, BACKEND_PORT as 8080, but then need to reverse proxy to port 80
Great :) Do you know how I can edit the Unraid template that is in the store?
You may reach out directly to this guy, He added pocket id to Unraid Community Apps -> https://github.com/nwithan8/unraid_templates Or You can create Your own template as a pocket id dev. Here is some useful link -> https://selfhosters.net/docker/templating/templating/ Alternatively, someone who will use nwithan8 template should modify template by yourself before creating a docker container. (nah... )
Was just debugging this last night. Glad someone figured out what the problem was already. Pushing out an updated template now, sorry about that.
EDIT: Update has been pushed. Templates usually populate on the Unraid Community Apps store within two hours.
EDIT 2: The Unraid app feed has been inconsistent for the past few days. Looks like it hasn't updated since I merged in the fixed template, so it's not available yet.
Reproduction steps
Installed from Unraid, I'm using SWAG (Nginx) Reverse Proxy, so I have setup https://id.example.com to reverse proxy to http://pocketid:3000, however the logs show
Failed to get application configuration: connect ECONNREFUSED 192.168.7.127:443
Variable is updated appropriately, see Unraid's run command below:Expected behavior
Allow me to create first user/login.
Actual Behavior