pysshops is a comodity pacakge to build python operations tools working on ssh and powered by paramiko.
from pysshops import SshOps
sshops = SshOps('hostname.domain.it', 'username')
with sshops as ssh:
ssh.remote_command('ls -l /var/tmp')
from pysshops import SftpOps
sftpops = SftpOps('hostname.domain.it', 'username')
with sftpops as sftp:
sftp.deploy('pysshops_sftp', '/tmp/pysshops_sftp')
git clone
cd pysshops
python setup.py install
pip install pysshops
- simple
- powered by rock-solid paramiko
- python2/3 compatibility
- both ssh and sftp facilities
- external key based authentication at os level