Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

 

Covalent SSH Plugin

Covalent is a Pythonic workflow tool used to execute tasks on advanced computing hardware. This executor plugin interfaces Covalent with other machines accessible to the user over SSH. It is appropriate to use this plugin to distribute tasks to one or more compute backends which are not controlled by a cluster management system, such as computers on a LAN, or even a collection of small-form-factor Linux-based devices such as Raspberry Pis, NVIDIA Jetsons, or Xeon Phi co-processors.

To use this plugin with Covalent, simply install it using pip:

pip install covalent-ssh-plugin

The following shows an example of how a user might modify their Covalent configuration to support this plugin:

[executors.ssh]
username = "user"
hostname = "host.hostname.org"
remote_cache_dir = "/home/user/.cache/covalent"
ssh_key_file = "/home/user/.ssh/id_rsa"
python_path = "/home/centos/miniconda3/envs/my-python-3.8-env/bin/python"

Note that python_path is optional (see below for more information).

This setup assumes the user has the ability to connect to the remote machine using ssh -i /home/user/.ssh/id_rsa user@host.hostname.org and has write-permissions on the remote directory /home/user/.cache/covalent (if it exists) or the closest parent directory (if it does not).

It may be necessary to specify the absolute path to python that you are using if you rely on activating a virtualenv to manage your python dependencies on your remote machine. For example when creating a new conda environment you can explicitly specify the python path by using the python_path configuration option (as above) otherwise it will default to resolving your python installation with which python.

Within a workflow, users can decorate electrons using the default settings:

import covalent as ct

@ct.electron(executor="ssh")
def my_task():
    import socket
    return socket.gethostname()

or use a class object to customize behavior within particular tasks:

executor = ct.executor.SSHExecutor(
    username="user",
    hostname="host2.hostname.org",
    remote_cache_dir="/tmp/covalent",
    ssh_key_file="/home/user/.ssh/host2/id_rsa",
    python_path="/home/centos/miniconda3/envs/my-python-3.8-env/bin/python"
)

@ct.electron(executor=executor)
def my_custom_task(x, y):
    return x + y

For more information on how to get started with Covalent, check out the project homepage and the official documentation.

Release Notes

Release notes are available in the Changelog.

Citation

Please use the following citation in any publications:

W. J. Cunningham, S. K. Radha, F. Hasan, J. Kanem, S. W. Neagle, and S. Sanand. Covalent. Zenodo, 2022. https://doi.org/10.5281/zenodo.5903364

License

Covalent is licensed under the GNU Affero GPL 3.0 License. Covalent may be distributed under other licenses upon request. See the LICENSE file or contact the support team for more details.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

covalent-ssh-plugin-0.7.0rc0.tar.gz (21.9 kB view details)

Uploaded Source

File details

Details for the file covalent-ssh-plugin-0.7.0rc0.tar.gz.

File metadata

  • Download URL: covalent-ssh-plugin-0.7.0rc0.tar.gz
  • Upload date:
  • Size: 21.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.13

File hashes

Hashes for covalent-ssh-plugin-0.7.0rc0.tar.gz
Algorithm Hash digest
SHA256 ed154381e434aff5edbe4bac91c4a17d1e43067a42977d444d1df9bb7521f731
MD5 ba43e3375dd4d6fc2ae96a80c39e0da2
BLAKE2b-256 3623c428fcf011aab8fbac93ad6d48c8dc16b1f8ba92acf1a85f6cbdb6b21c77

See more details on using hashes here.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page