Give FTP users access to specific dir's

Is there a way to FTP users access to specific dirs? Not just domains because i know you can do that but say i want a user to just have ftp access to and not anything else at just the publications dir.

Setup the second user. Then use the Remap Sub-dir option to map /publications to /home/seconduser/publications

Beware ownership and permission issues may prevent CGI from working though.

:cool: [color=#6600CC]Atropos[/color] |

ok. please somebody corrects me if i am wrong.

sorry asasu, i’m not sure about my suggestion and maybe I’m mis-leading you :P.

It seems it is not possible to set up a FTP user to access a specific direcotry in DH. You may want to try to do this by creating a htaccess file. But I’m not sure.

What i suggest is:

  1. create a user1 for your domain.
  2. create a subdomain of your domain.
  3. create a user2 for your sudomain.

now user1 has access to domain. user2 has access to sudomain.

  1. go to DH panel --> Domains --> Remap Sub-Dir to remap the folder in your domain which you want to control to a folder in your subdomain.

Have I done?

user2 has access only to subdomain and the subodmain contains the folder of your domain because of remapping.

Please note that I haven’t tried it out yet. I can’t guarantee it will work

[color=#CC0000]and please don’t laught at me if I mis-understand the meaning of remap[/color]

Save [color=#CC0000]$97[/color] (max discount) on dreamhost plans by using promo code: [color=#CC0000]97CRAZY[/color].

Thank you this sounds like it is going to work, i just didn’t want to give this user access to the entire domain, they just need to work on a side project

This works but it is kind of annoying because now the files sit in that account and so i have to log out and log back in if i want to access them or if they change their password then i have to be notified of it. I like the solution but is there anything else? I wish you could just modify the users home directory, maybe a dreamhost fix in the future?

I can’t count the number of times this has come up, especially recently, and the answers you have been given are correct for your question.

What I don’t understand is why everyone seems to insist on using ftp accounts for this type of functionality. A simple “filemanager” or “upload” script placed in the appropriaate directory, with access controlled either by .htaccess based Apache authentication or the scripts “built-in” login process, seems to me to be the best way to handle stuff like this.

The files retain the same owner as the CGI user (generally, you), and the freely available script’s out there allow great flexibility (allowing you to limit space used, types of files uploaded, etc.).

To me, this seems the simpler, more efficient, and generally preferable way to go. Of course, YMMV. :wink:


a file upload or filemanager type of script won’t really work since they will be actually editing the pages and i would rather them be able to do it through software such as dreamweaver since this is what they prefer. This way they have access the the directory in a familiar format. So the solution would be to make a script to run the uploads and just browse the dirs?

For the situation you describe, that makes sense. :wink: Good luck with getting set up in a way that works well for you! Have you thoroughly investigated setting up *nix groups to facilitate this?


wow webdav is amazing i didn’t even know what it was until you brought it up. This works beautifully i just have dreamweaver setup to access it and it does exactly what i was thinking of. Thank you for the suggestion i also went ahead and added this to the wiki as another solution to the ftp user section since there is a section in there talking about giving users access to a specific subdir

I’m glad you found a solution that works…though I don’t think it was me that suggested webdav :wink: .