Paramiko SSH & SCP Tutorial
Source code for the accompanying tutorial found here: https://hackersandslackers.com/ssh-scp-in-python-with-paramiko/
Installation
Installation via requirements.txt:
$ git clone https://github.com/hackersandslackers/paramiko-tutorial.git
$ cd paramiko-tutorial
$ python3 -m venv myenv
$ source myenv/bin/activate
$ pip3 install -r requirements.txt
$ python3 main.pyInstallation via Pipenv:
$ git clone https://github.com/hackersandslackers/paramiko-tutorial.git
$ cd paramiko-tutorial
$ pipenv shell
$ pipenv update
$ python3 main.pyInstallation via Poetry:
$ git clone https://github.com/hackersandslackers/paramiko-tutorial.git
$ cd paramiko-tutorial
$ poetry shell
$ poetry update
$ poetry runUsage
Replace the values in .env.example with your values and rename this file to .env:
REMOTE_HOST: IP address or URL of remote host.REMOTE_USERNAME: Username for remote host.SSH_KEY: /path/to/remote/host/sshkey.pemREMOTE_PATH(optional): Remote directory to serve as destination for file uploads.
Remember to never commit secrets saved in .env files to Github.
Hackers and Slackers tutorials are free of charge. If you found this tutorial helpful, a small donation would be greatly appreciated to keep us in business. All proceeds go towards coffee, and all coffee goes towards more content.

Formed in 2009, the Archive Team (not to be confused with the archive.org Archive-It Team) is a rogue archivist collective dedicated to saving copies of rapidly dying or deleted websites for the sake of history and digital heritage. The group is 100% composed of volunteers and interested parties, and has expanded into a large amount of related projects for saving online and digital history.

