Answer the question
In order to leave comments, you need to log in
How to create external user ubuntu server?
I can't figure out how to create a user for a specific directory in ubuntu server. I read a lot of manuals, but I did not meet normal ones. Either the user can leave his directory, or something else. Trying to make it so that a specific user only has access to a specific folder on the server and can connect there via SSH and SFTP so that he can't leave that folder but can edit all the files in the folder he's been given + work with GIT via SSH.
With the usual creation of a user in ubuntu, he can immediately connect to SSH and view all the files on the server, but not edit them. Here, as I understand it, you just need to remove access and read access to some files.
After editing the sshd_config file:
Match User john
ChrootDirectory /home/john
ForceCommand internal-sftp
AllowTCPForwarding no
X11Forwarding no
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question