For certain resources such as campus clusters or supercomputers at research laboratories, resource requirements may require authentication. For instance some resources may allow access to their job schedulers from only their login-nodes which require you to authenticate on through SSH, GSI-SSH and sometimes even require two factor authentication. Channels are simple abstractions that enable the ExecutionProvider component to talk to the resource managers of compute facilities. The simplest Channel, LocalChannel, simply executes commands locally on a shell, while the SshChannel authenticates you to remote systems.
Channels are usually called via the execute_wait function. For channels that execute remotely, a push_file function allows you to copy over files.
+------------------ | cmd, wtime ------->| execute_wait (ec, stdout, stderr)<-|---+ | src, dst_dir ------->| push_file dst_path <--------|----+ | dst_script_dir <------| script_dir | +-------------------
Channels should ensure that each launched command runs in a new process group, so that providers (such as AdHocProvider and LocalProvider) which terminate long running commands using process groups can do so.
Initialize self. See help(type(self)) for accurate signature.
Return the absolute path.
Closes the channel.
execute_wait(cmd[, walltime, envs])
Executes the cmd, with a defined walltime.
Return true if the path refers to an existing directory.
makedirs(path[, mode, exist_ok])
Create a directory.
Transport file on the remote side to a local directory
Channel will take care of moving the file from source to the destination directory
This is a property.