iis - 使用 get-website 搜索绑定(bind)?

标签 iis powershell

为什么我不能做一个简单的:

Get-Website | where { $_.Bindings -like "*DOMAIN*" }

关于绑定(bind)?但它在名称和物理路径上运行良好吗? 有什么方法可以使用 get-website 对绑定(bind)进行搜索吗?

最佳答案

因为可以有多个绑定(bind)。您必须迭代它们中的每一个:

Get-Website | 
    Select-Object Bindings |
    Where { $_.BindingInformation -like '*DOMAIN*' }

关于iis - 使用 get-website 搜索绑定(bind)?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10970797/

相关文章:

windows - IIS 多个站点在同一个 ip 上,具有不同的 ssl

powershell - 使用 get-children 列出带有 lastwritetime 的文件

powershell - 如何获取字符串格式的对象成员

visual-studio-2010 - 如何执行与从Powershell中发布Visual Studio中的发布完全相同的功能

powershell - 在 PowerShell 中连接或使用 heredoc 时保留换行符

c# - 从 C# 代码安装 IIS

web-services - IIS中“默认网站”的IP地址“自动”更改

asp.net-mvc - IIS Express 子应用程序配置继承

c# - Request.ServerVariables ["LOGON_USER"] 与 Request.LogonUserIdentity

powershell - 如何创建一个循环以将结果作为函数的新参数反馈? (电源外壳)