Jeeaaasus / youtube-dl

Automated yt-dlp Docker image
https://hub.docker.com/r/jeeaaasustest/youtube-dl/
MIT License
258 stars 33 forks source link

CIFS Permission Denied #86

Closed dillwishlist closed 1 year ago

dillwishlist commented 1 year ago

Hello,

I'm mounting /downloads as a CIFS/SMB share on my NAS. I can log in with the docker exec console and create directories and folders as you would expect, so things seem to be set properly on the share end permission wise.

However when the container auto-runs the download, I get the following: ERROR: unable to create directory [Errno 13] Permission denied: '/downloads/Songs for Littles - Toddler Learning Videos' Any thoughts on how to correct this?

Thanks!

dillwishlist commented 1 year ago

To clarify, the mount is achieved through docker (portainer) directly, not through the container.

dillwishlist commented 1 year ago

Answering my own question. Set the PUID and PGID environment variables to 0 fixes this issue.

Jeeaaasus commented 1 year ago

When you logged in by using docker exec you probably logged in as root to the container? The user that runs yt-dlp is called "abc". The PU/PG-ID you need to use is one that is permitted to write on the mount, yes 0 should always work, but never recommended.

I have a very similar setup and I use 1000, which is my user on my docker host that is permitted to write on my nas mount.