Config directory permissions



I’ve followed the instructions from Docker Hub but am having a hard time figuring out what I’m doing wrong here. I need the container to do any reading or writing in the config, transcode temp, and data directories as UID and GID 1000.

I have the container configured via docker compose like so:

        image: plexinc/pms-docker:public
            - "32400:32400"
            - "3005:3005"
            - "8324:8324"
            - "32469:32469"
            - "1900:1900/udp"
            - "32410:32410/udp"
            - "32412:32412/udp"
            - "32413:32413/udp"
            - "32414:32414/udp"
            - /zahra/plex_data/transcode_temp:/transcode
            - /zahra/plex_data/config:/config
            - /zahra:/data
            - TZ=America\Chicago
            - PLEX_CLAIM=claim
            - ADVERTISE_IP=
            - PLEX_UID=1000
            - PLEX_GID=1000

There was nothing in the /zahra/plex_data/config or /zahra/plex_data/transcode_temp directories prior to me running the container. When I first ran it, I got a permission denied error so I looked to see what files had been written, and they’re written as my user (1000). Which is correct, this is what I want.

After stopping and starting the container again, I get a lot of stuff like this:

plexms_1  | Permission denied: /config/Library/Application Support/Plex Media Server/Preferences.xml
plexms_1  | Permission denied: /config/Library/Application Support/Plex Media Server/Preferences.xml
plexms_1  | failed to load external entity "/config/Library/Application Support/Plex Media Server/Preferences.xml"

Anybody see what I’m doing wrong here?


It'd help to have more content on the error messages. Are they the docker logs for the container? There are setup scripts within the container which do access the preferences file (especially since you are using the public tag) and these setup scripts are running as root within the container. You may have docker configured so that this root user doesn't have actual root permissions when running inside the container. This could be the issue with the permission denied you are seeing.

Also, for the TZ, it's America/Chicago, not America\Chicago (wrong slash).


The error messages I posted were from the docker logs, yes. Helpful to know that not everything is run by that plex user. These volumes are mounted NFS shares so needed no_root_squash on the server's side.



I think you could root squash to UID 1000 and it'd still work. Obviously the chown operations wouldn't work but they are run only the first time and you have that off anyway.


This is now a completely moot point because I ran into the "plex freezing over nfs" issue. I've moved the config to the local machine to avoid this.


Oh I should have mentioned that. I've tried to do the config dir over NFS/SMB several times and each time I came away with a corrupt database within a week. You can have the media on remote mounts, but anything with a sqlite db just doesn't seem to work (I've seen the same with other containers that use sqlite databases).