Skip to main content
April 26, 2023
Question

Use 1password to manage ssh keys in WSL

  • April 26, 2023
  • 5 replies
  • 426 views

I have a Windows laptop, but use the WSL for development.

How can I use 1password to manage ssh keys for me for GitHub?

The document https://developer.1password.com/docs/ssh/agent assumes you're using a Windows app and then using ssh keys on Windows. However, I am using the Windows app but ssh keys in Linux


1Password Version: 8.10.5
Extension Version: Not Provided
OS Version: windows 11 pro
Browser:_ firefox

5 replies

April 28, 2023

I talk about my experience of getting 1Password working with WSL2 https://justinbarclay.ca/posts/crossing-the-void-with-1password-and-wsl2/, but the TLDR is to call the Windows version of SSH directly in your git config

[core]
sshProgram = "ssh.exe"

May 8, 2023

This worked perfectly, thank you so much!

In summary, I followed the windows instructions, and then, in wsl, in ~/.gitconfig, I put

[core]
sshCommand = "ssh.exe"

May 26, 2023

Thanks for sharing your solution and blogpost, @justinbarclay! Glad to hear it resolved your issue, @marcogorelli.

May 26, 2023

any chance this could be added to the docs please?

May 26, 2023

@marcogorelli we're looking into adding this to our official docs.