Hi, new Joplin Server user here:
Using docker-compose on proxmox, I got to the point where the web interface works, I created a second user, changed the password twice, the second user can login in the web, and the client (joplin-desktop on arch) gives success on the sync check. But actually trying to sync fails with: Error: GET api/files/root://info.json:/content: Unknown error (500): {"error":"Cannot read property 'id' of null"}
The server logs have this for each try:
joplin | 2021-03-21 15:16:01: App: GET /api/files/root://info.json:/content
joplin | 2021-03-21 15:16:01: [error] App: TypeError: Cannot read property 'id' of null
joplin | at /home/joplin/packages/server/src/routes/api/files.ts:48:56
joplin | at Generator.next (<anonymous>)
joplin | at /home/joplin/packages/server/dist/routes/api/files.js:8:71
joplin | at new Promise (<anonymous>)
joplin | at __awaiter (/home/joplin/packages/server/dist/routes/api/files.js:4:12)
joplin | at /home/joplin/packages/server/src/routes/api/files.ts:47:78
joplin | at /home/joplin/packages/server/src/middleware/routeHandler.ts:19:27
joplin | at Generator.next (<anonymous>)
joplin | at /home/joplin/packages/server/dist/middleware/routeHandler.js:8:71
joplin | at new Promise (<anonymous>)
joplin | at __awaiter (/home/joplin/packages/server/dist/middleware/routeHandler.js:4:12)
joplin | at default_1 (/home/joplin/packages/server/dist/middleware/routeHandler.js:18:12)
joplin | at dispatch (/home/joplin/packages/server/node_modules/koa-compose/index.js:42:32)
joplin | at /home/joplin/packages/server/src/middleware/notificationHandler.ts:75:33
joplin | at Generator.next (<anonymous>)
joplin | at /home/joplin/packages/server/dist/middleware/notificationHandler.js:8:71
joplin | 2021-03-21 15:16:11: App: GET /api/files/root://info.json:/content
joplin | 2021-03-21 15:16:11: [error] App: TypeError: Cannot read property 'id' of null
joplin | at /home/joplin/packages/server/src/routes/api/files.ts:48:56
joplin | at Generator.next (<anonymous>)
joplin | at /home/joplin/packages/server/dist/routes/api/files.js:8:71
joplin | at new Promise (<anonymous>)
joplin | at __awaiter (/home/joplin/packages/server/dist/routes/api/files.js:4:12)
joplin | at /home/joplin/packages/server/src/routes/api/files.ts:47:78
joplin | at /home/joplin/packages/server/src/middleware/routeHandler.ts:19:27
joplin | at Generator.next (<anonymous>)
joplin | at /home/joplin/packages/server/dist/middleware/routeHandler.js:8:71
joplin | at new Promise (<anonymous>)
joplin | at __awaiter (/home/joplin/packages/server/dist/middleware/routeHandler.js:4:12)
joplin | at default_1 (/home/joplin/packages/server/dist/middleware/routeHandler.js:18:12)
joplin | at dispatch (/home/joplin/packages/server/node_modules/koa-compose/index.js:42:32)
joplin | at /home/joplin/packages/server/src/middleware/notificationHandler.ts:75:33
joplin | at Generator.next (<anonymous>)
joplin | at /home/joplin/packages/server/dist/middleware/notificationHandler.js:8:71
from my client:
curl https://joplin.mydomain.org/api/ping
{"status":"ok","message":"Joplin Server is running"}
I first thought it had to do with the database bound volume permissions, but I reverted back to the default (no volume bound). Now I guess it's about the reverse proxy setup, which I couldn't find much info about. I'm using caddy with just a simple everse proxy directive and externally-obtained certs
joplin.mydomain.org:443 {
tls {
protocols tls1.3
load /certdirectory/
}
reverse_proxy joplin:22300
}
my docker-compose:
version: '3'
services:
joplindb:
image: postgres:13.2
container_name: joplindb
ports:
- "5432:5432"
restart: unless-stopped
env_file:
- ../joplin/secrets/joplin.env
networks:
bridgejoplinprivate:
joplin:
image: joplin/server:latest
container_name: joplin
depends_on:
- joplindb
ports:
- "22300:22300"
restart: unless-stopped
env_file:
- ../joplin/secrets/joplin.env
environment:
- DB_CLIENT=pg
- POSTGRES_HOST=joplindb
networks:
bridgejoplinprivate:
bridgejoplin:
networks:
bridgejoplinprivate: #internal db-app bridge
driver: bridge
bridgejoplin: #connected to caddy
external: true
What am I doing wrong?
Thanks