I want the transmission-daemon to have permission to write to a directory called
/opt/www/ that already has the owner set to www-data(in order for the web server to serve files in it)
The transmission daemon responds with a permission denied error when I set it to my download directory. How can I give it permission to write in this directory while maintaining the www-data ownership?
Sorry if it’s a bit confusing I will clarify if I was unclear.
/opt/www needs www-data to be able to be served as a webpage, but at the same time I want transmission to be able to write files to that folder. How can I do that? By default transmission runs on the user debian-transmission
Here is Solutions:
We have many solutions to this problem, But we recommend you to use the first solution because it is tested & true solution that will 100% work for you.
debian-transmission write permission on the directory using ACLs:
sudo setfacl -Rm u:debian-transmission:rwX /opt/www sudo setfacl -Rdm u:debian-transmission:rwX /opt/www
This sets both the current permissions and default permissions (ones inherited by new files/folders).
Note: Use and implement solution 1 because this method fully tested our system.
Thank you 🙂