Skip to content

Instantly share code, notes, and snippets.

@MVesuviusC
Last active August 18, 2023 16:06
Show Gist options
  • Save MVesuviusC/39c5596de2e27c49882fe51fbed5d241 to your computer and use it in GitHub Desktop.
Save MVesuviusC/39c5596de2e27c49882fe51fbed5d241 to your computer and use it in GitHub Desktop.
vscode automatic login
vscode auto login
From:
https://stackoverflow.com/questions/66113731/how-to-save-ssh-password-to-vscode
on local machine (windows) in powershell run:
# Change my pathway to your username #
ssh-keygen -q -b 2048 -f /Users/mvc002/.ssh/keys/franklin_rsa -t rsa
hit enter twice to skip entering a password
Open up the franklin_rsa.pub file in notepad and copy the contents
Paste into ~/.ssh/authorized_keys (create it if it's not there)
Make sure the xauth.exe exists here, if not get it or find it:
C:\Progra~1\VcXsrv\xauth.exe
Add this to your remote ssh config file:
Host r1pl-hpcf-log01
HostName r1pl-hpcf-log01
User mvc002
ForwardX11 yes
ForwardX11Trusted yes
XAuthLocation "C:\Progra~1\VcXsrv\xauth.exe"
PreferredAuthentications publickey
IdentityFile "C:\Users\mvc002\.ssh\franklin_rsa"
log in, should not require password
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment