Skip to content
docker sftp
2025年3月13日 root

install

shell
docker run -it -p 8000:80 -p 8001:21 -p 8002:22 -p 8003:443 -v /home/sftp:/root --name sftp debian /bin/bash
apt install ssh -y
/etc/init.d/ssh start 
passwd

config

shell
nano /etc/ssh/sshd_config
``` shell

``` config
PermitRootLogin yes
ChallengeResponseAuthentication yes
shell
/etc/init.d/ssh restart

test

shell
 sftp -P 8002 root@x.x.x.x

Last updated: