By saband
Hello. I have some user, for example, “example” :) And his home directory is /var/www/example/, where are sites folders (/var/www/example/example.com). For ftp access I use this user’s login “example” and his password. But. I need to create another one ftp user, with access to the folder /var/www/example/example.com/subfolder and only to this folder. I can’t create a unix user with such home directory. Is there a way to resolve this problem?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Indeed. I just tried to use already existing directory as home, that’s why it didn’t work. Thank you.
Actually, you can create a user with /var/www/example/example.com/subfolder as its home directory:
adduser --home /var/www/example/example.com/subfolder --group username
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.