One line ftp server in python

前端 未结 9 1811
清歌不尽
清歌不尽 2020-12-07 08:03

Is it possible to have a one line command in python to do a simple ftp server? I\'d like to be able to do this as quick and temporary way to transfer files to a linux box wi

9条回答
  •  离开以前
    2020-12-07 08:08

    For pyftpdlib users. I found this on the pyftpdlib website. This creates anonymous ftp with write access to your filesystem so please use with due care. More features are available under the hood for better security so just go look:

    sudo pip3 install pyftpdlib
    
    python3 -m pyftpdlib -w  
    
    ## updated for python3 Feb14:2020
    

    Might be helpful for those that tried using the deprecated method above.

    sudo python -m pyftpdlib.ftpserver

提交回复
热议问题