我知道连接到远程运行空间的唯一方法包括以下参数
WSManConnectionInfo connectionInfo =
new WSManConnectionInfo(false, "localhost", 80, "/Powershell", "http://schemas.microsoft.com/powershell/Microsoft.Exchange", credential);
Run Code Online (Sandbox Code Playgroud)
要么
WSManConnectionInfo connectionInfo =
new WSManConnectionInfo(false, "localhost", 5985, "/wsman", "http://schemas.microsoft.com/powershell/Microsoft.Powershell", credential);
Run Code Online (Sandbox Code Playgroud)
如何设置我自己的自定义Powershell对象,以便通过HTTP公开它?
使用的正确参数是什么以及如何设置它们?