Skip to content

Instantly share code, notes, and snippets.

@saileshkush95
Last active March 8, 2020 09:31
Show Gist options
  • Save saileshkush95/75bf4194ac2f3c56a36b14a6ea26b5a6 to your computer and use it in GitHub Desktop.
Save saileshkush95/75bf4194ac2f3c56a36b14a6ea26b5a6 to your computer and use it in GitHub Desktop.
1. To copy files between your computer and your instance you can use an FTP service like FileZilla or the command scp which stands for secure copy.
2. To use scp with a key pair use the following command: scp -i path/to/key file/to/copy [email protected]:path/to/file.
3. To use it without a key pair, just omit the flag -i and type in the password of the user when prompted.
4. To copy an entire directory, add the -r recursive option: scp -i path/to/key -r directory/to/copy [email protected]:path/to/directory.
Example:
scp -i /Users/macbook/Documents/SandeepPythonDev.pem -r /Users/macbook/Desktop/KathmanduCottege [email protected]:/home/sandeep/DevOps/PythonProjects
If not work use sudo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment