Virtual hosts user management
I want to create users so that can S/FTP to a specific directory of a single domain.
Anyone can point me in the right direction? A linode library article perhaps?
[Edit] Like Musfuut pointed out, I forgot to mention the flavor of linux I'm using. Ubuntu
I just recently set up a jailed sftp for our web designer to have access to "his" content.
It isn't too too hard to set up.
That looks like it should do the trick.
I've been looking on the library but I think I was missing a…search criteria.
Now, the way I read this is that I am creating a user and giving access to the user through sftp to that users home directory and that's it.
The thing is that I want my user to be able to manage the files inside the public_html of a domain, let's say:
I'm not sure this accomplishes the same thing.
Then have your directory
you make sure root owns srv, www, and my-domain.com
The user needs to own public_html and the files inside of it
then edit /etc/ssh/sshd_config per the instructions
set their chroot directory to /srv/www/my-domain.com/
When they log in they will be resticted to my-domain.com and whatever folders are inside of it, including public_html.
Hope this helps, write back if you have any more questions.
I also just ended up on this
One question. I need to have some directories (cache, logs) to be owned by the www-data user so my app can write to them. So, if I change the ownership of my-domain.com then I need to later reassign those back to the www-data user, right?