Last active
November 26, 2018 07:00
-
-
Save DonerKebab/051505edc3ee6cde5ec09ce32d699a9f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo groupadd ftpaccess | |
sudo nano /etc/ssh/sshd_config | |
Add these lines to the bottom: | |
Match Group ftpaccess | |
ChrootDirectory /data/%u | |
ForceCommand internal-sftp | |
sudo service ssh restart | |
sudo userdel -r giffgaff | |
sudo useradd -m giffgaff -g ftpaccess -s /usr/sbin/nologin | |
sudo passwd giffgaff | |
sudo chown root /home/giffgaff | |
sudo mkdir /home/giffgaff/leads | |
sudo chown giffgaff:ftpaccess /home/giffgaff/leads |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment