ssh key로 서버 접속 - g-market/b-shop-backend GitHub Wiki

ssh로 VM 서버에 접속하는 방법

  1. id_rsa 다운로드 하고 이동
  • C:\Users\User\.ssh
  1. 클라이언트 pc ssh-agent에 키 등록
  • PowerShell 관리자 권한으로 실행
# By default the ssh-agent service is disabled. Allow it to be manually started for the next step to work.
# Make sure you're running as an Administrator.
Get-Service ssh-agent | Set-Service -StartupType Manual

# Start the service
Start-Service ssh-agent

# This should return a status of Running
Get-Service ssh-agent

# Now load your key files into ssh-agent
ssh-add C:\Users\User\.ssh\id_rsa
  1. 다음 명령어로 서버 VM으로 로그인!
ssh [email protected]