0

[UBUNTU 20.04]

Is it possible, that every upload I make (through sFTP clients, like winscp,filezilla or whatever) , the owner was set to www-data instead of root? If possible to give examples for any of the above mentioned sFTP clients, I will be glad.

5
  • " for any of the above mentioned sFTP clients" Why would a CLIENT be the one to set the owner? It is the server that does that. Check the config file for the server you installed to do this. It will have a setting for owner, group and permissions for dirs and files.
    – Rinzwind
    May 15, 2021 at 20:06
  • @Rinzwind I don't agree with you, your concern is just too beaurocratic. Client programs nowadays (in any field) are very customizable and (to my surprise too) accommodate some handy functionalities. To name some of them, it's enough i.e. VSCode, which is pure Code editor, but has integrated GIT functionality (while this former is TOTALLY different field). However, handy shortcuts/functionalities enrich clients. That's why I asked, if someone knew it. in WinScp, it's several clicks to change ownership, so automating that process might have been possible, so my question seems legit.
    – T.Todua
    May 15, 2021 at 20:13
  • Nope. It is the SERVER that is allowing it. Oh and winscp seems pretty odd to mention: that is a pure windows tool. The server handles all the requests and executes them. From the client you can only ask to do so. On Ubuntu the go to tool is openssh.
    – Rinzwind
    May 15, 2021 at 21:16
  • 1
    This sounds like a code-deployment process that could use some modernization. That said, if you insist, then a job could be created using inotify to monitor file changes in the directories you choose. Files that are created or modified can then have their ownership and/or permissions updated as required.
    – matigo
    May 15, 2021 at 23:08
  • @matigo if you convert that to answer, i will upvote.
    – T.Todua
    May 16, 2021 at 7:50

0

You must log in to answer this question.

Browse other questions tagged .