在 Windows PowerShell 中:
>ssh -i \Path\To\key.pem user@server.com
像冠军一样工作。
>Set-alias sshalias "ssh -i \Path\To\key.pem user@server.com"
保存别名时没有错误。
>sshalias
返回以下错误:
sshalias : The module 'ssh -i ' could not be loaded. For more information, run 'Import-Module ssh -i '.
At line:1 char:1
+ sshalias
+ CategoryInfo : ObjectNotFound: (ssh -i \Path\To\Key.pem user@server.com:String) [], CommandNotFoundException
`+ FullyQualifiedErrorId : CouldNotAutoLoadModule`
Run Code Online (Sandbox Code Playgroud)
我缺少什么?