I want to run the eclipse-mosquitto mqtt server in a docker on a RPi.
The command I am using to run it is:
docker run --name mqtt --restart=always --net=host -tid -u 1883:1883 -v /opt/mosquitto/config:/mosquitto/config:ro -v /opt/mosquitto/log:/mosquitto/log:rw -v /opt/mosquitto/data/:/mosquitto/data/:rw eclipse-mosquitto
When starting up the server, I am getting the following error message:
1615232346: Error: Unable to open log file /opt/mosquitto/log/mosquitto.log for writing.
Also from time to time I am getting the following error in the docker logs:
1615241350: Error: No such file or directory.
I assume this one is for the unwriteable data directory.
My mosquitto user looks like this:

The rights to the folders in /opt/mosquitto/ looke like this:

I even changed the access rights for the mosquitto.log to 777:

Unfortunately I am still getting the error. The server is up and running though, but I cannot access the logs and nothing can be written in the data directory. I also already checked multiple solutions (e.g. https://github.com/eclipse/mosquitto/issues/909), but nothing has worked so far.
Can you help me out how to solve this?