FTP Filesystem

Manage filesystems on remote FTP servers.

class fs.ftpfs.FTPFS(host, user=u'anonymous', passwd=u'', acct=u'', timeout=10, port=21, proxy=None)[source]

A FTP (File Transport Protocol) Filesystem.

Parameters:
  • host (str) – A FTP host, e.g. 'ftp.mirror.nl'.
  • user (str) – A username (default is 'anonymous').
  • passwd (str) – Password for the server, or None for anon.
  • acct (str) – FTP account.
  • timeout (int) – Timeout for contacting server (in seconds, defaults to 10).
  • port (int) – FTP port number (default 21).
  • proxy (str, optional) – An FTP proxy, or None (default) for no proxy.
features

features of the remote FTP server.

Type:dict
ftp

the underlying FTP client.

Type:FTP
ftp_url

Get the FTP url this filesystem will open.

geturl(path, purpose=u'download')[source]

Get FTP url for resource.

supports_mlst

whether the server supports MLST feature.

Type:bool