cherab.nagdis.tools.fetch.fetch_fileΒΆ

cherab.nagdis.tools.fetch.fetch_file(name: str, host: str = 'sftp://133.6.100.44/home/koyo/cherab/nagdis/', username: str = 'koyo', password: str = 'password') strSourceΒΆ

Fetch the file from the remote server using the configured SFTP downloader.

Fetched data will be stored in the cache directory like cache/cherab/nagdis.

Parameters:
name: strΒΆ

Name of the file to fetch.

host: str = 'sftp://133.6.100.44/home/koyo/cherab/nagdis/'ΒΆ

Host name of the server, by default sftp://example.com/. This value is adaptable from the environment variable SSH_RAYTRACE_HOSTNAME. Host name should be in the format sftp://{host's name or ip}/{directories}.

username: str = 'koyo'ΒΆ

Username to authenticate with the server, by default username. This value is adaptable from the environment variable SSH_RAYTRACE_USERNAME.

password: str = 'password'ΒΆ

Password to authenticate with the server, by default password. This value is adaptable from the environment variable SSH_RAYTRACE_PASSWORD.

Returns:

str – Path to the fetched file.