title: How to add a passphrase into a script for a scp command
body: <p>I have a script which should simply copy some file from Server A to Server B. To be able to do so, during the script is running I am asked to manually type the Passphrase. My question is how can I automate that, so the Passphrase is automatically added? </p>
  
  <pre class="lang-sh prettyprint-override"><code>scp -i ${SCPKEY} ${SCPFILETOCOPY} ${SCPUSER}@${SCPDEST}
  </code></pre>
  
  <p>this is an example of the command I use in the script</p>
  
  <p>I couldn't find any solution on the web. I tried using the <code>sshpass</code> but it did not work...</p>
  
  <p>The Problem is basically with the 2 side authentication.</p>
  
  <p>Thank you in advance for all your help!</p>