Joplin server error (can't run without root)

Tried Joplin server, after I run the Joplin docker container it gives me, while the Database says it is ready to accept connections

[Error: ENOENT: no such file or directory, mkdir '/home/joplin/packages/server/logs'] {

errno: -2,
code: 'ENOENT',
syscall: 'mkdir',
path: '/home/joplin/packages/server/logs'

Used the following code

docker run -d --name jopdb \
    --network=eight_net \
    -v /srv/docker/JoplinDb:/var/lib/postgresql/data \
    -p 5432:5432 \
    -e POSTGRES_PASSWORD=jop@ \
    -e POSTGRES_USER=jop \
    -e POSTGRES_DB=db \
    --ip=192.168.1.195 \
    --restart unless-stopped \
    postgres:15

docker run -d --name joplin \
    --network=eight_net \
    -p 22300:22300 \
    -e APP_PORT=22300 \
    -e APP_BASE_URL=https://mydom.duckdns.org/notesync \
    -e DB_CLIENT=pg \
    -e POSTGRES_PASSWORD=jop@ \
    -e POSTGRES_DATABASE=db \
    -e POSTGRES_USER=jop \
    -e POSTGRES_PORT=5432 \
    -e POSTGRES_HOST=192.168.1.195 \
    --ip=192.168.1.192 \
    --restart unless-stopped \
    joplin/server:latest

Update : resolved it somewhat but I still feel there is a big issue here.

It was a permission issue, so I tried to pass -u 0:0 as variables to give it root access and it worked. Ofcourse I would be taking away the root access, it was just to check if permissions were causing it.

Now I don't understand why I can not run Joplin with any other permission but root.

I also tired giving access to Database folder with :slight_smile:

chown userofcontainer pathtofolder
chmod u+rwx pathtofolder

It still does not work. And I also tired passing the Database container with the same user, which shows permission error in logs.

So I am stuck with either running the Joplin Container as root, as the chown and chmod do not work, and neither can I pass Database with a the same user as Joplin (if I use anything other than root), as it would throw permission errors

I have the same problem on my VPS, while in my workstation all works.
I've tried with -u 0:0 parameter too, but nothing changes.
Any suggest?

PS: Docker version is the same on both machines.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.