Jailing a user and allowing write access via SFTP

Hey.

I'd like to setup a SFTP account for one of my clients to have access to the root of their site. While I was following this tutorial it seemed to work except I have to set the user's home directory as the directory for the domain and not the public_html folder.

So for example when my client logs in they see…

/ (domain.com)
    logs
    public_html

Instead I'd like them to only see the contents of public_hmtl. Doing this though means that they cannot create new files because root must be the owner of the home folder.

What I'd like them to see is…

/ (public_html)
    ...

I've browsed the internet for advice and checked out these forums but I'm not able to find the answer I'm after.

So my question is, what's the most efficient way allow a client to their public_html files via a client service like SFTP so that they can read and write without seeing the rest of the files on the server.

Any advice would be appreciated.

I'm running Ubuntu 10.10 (Maverick) and I have enough command line experience to get me by.

Many thanks.

0 Replies

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct