title: How do I get Visual Studio Code access to Bitbucket using an SSH key with a password
body: <p>I have a personal and professional Bitbucket account. I am able to access both via Git command line, but cannot get the professional account to work from within the Visual Studio Code GUI interface. </p>
  
  <p>The difference between the two accounts is that my professional account has a passphrase on the SSH key and prompts me for it when I access the remote repo. I cannot get Visual Studio Code to prompt me for the passphrase.</p>
  
  <p>When I try to use the GUI interface and push/pull my changes:
   <a href="https://i.stack.imgur.com/U8hIC.png" rel="noreferrer"><img src="https://i.stack.imgur.com/U8hIC.png" alt="enter image description here"></a></p>
  
  <p>I get an error reading ‘Git: git@bitbucket.org: Permission denied (publickey).’
   <a href="https://i.stack.imgur.com/3swXM.png" rel="noreferrer"><img src="https://i.stack.imgur.com/3swXM.png" alt="enter image description here"></a></p>
  
  <p>The git log output shows:</p>
  
  <p><a href="https://i.stack.imgur.com/2gtmo.png" rel="noreferrer"><img src="https://i.stack.imgur.com/2gtmo.png" alt="enter image description here"></a></p>
  
  <p>But if I jump in the integrated Terminal and ‘git push’ it is successful: 
   <a href="https://i.stack.imgur.com/WNQ3J.png" rel="noreferrer"><img src="https://i.stack.imgur.com/WNQ3J.png" alt="enter image description here"></a></p>
  
  <p>I have read through a lot of different approaches to fix this and none seem to be doing the trick.</p>
  
  <p>I have ssh-agent running. I have added the key to the agent. <code>ssh-add -L</code> shows the loaded key. </p>
  
  <p>I have added <code>"remote.SSH.showLoginTerminal": true,</code> and <code>"remote.SSH.useLocalServer": false</code> to the VS Code settings.json per the instructions provided on <a href="https://code.visualstudio.com/docs/remote/troubleshooting" rel="noreferrer">https://code.visualstudio.com/docs/remote/troubleshooting</a> This has no impact.</p>
  
  <p>I have added the Remote Development extension pack and followed instructions at <a href="https://code.visualstudio.com/docs/remote/ssh" rel="noreferrer">https://code.visualstudio.com/docs/remote/ssh</a> but was unable to complete them since Bitbucket shell access is disabled</p>
  
  <p>I have tried  adding <code>AddKeysToAgent yes</code> on the top of the .ssh/config file as was recommended in another post. This didn't change anything. </p>
  
  <p>I have tried <code>git config --global credential.helper cache</code> but it looks like that will only work with HTTPS, not SSH.</p>
  
  <p>Despite all that I have tried, VS Code still fails to connect with the error above. I can remove the passphrase from the key and it works fine, but I would like to make it work with the passphrase. </p>
  
  <p>What am I missing?</p>