Check out example codes for "upload zip file to ec2". It will help you in understanding the concepts better.

Code Example 1

$scp -i ~/Desktop/amazon.pem ~/Desktop/MS115.fa  [email protected]:~/data/

Code Example 2

$scp -i ~/Desktop/amazon.pem ~/Desktop/MS115.fa  [email protected]:~/data/

Learn ReactJs, React Native from akashmittal.com