IIS站点和nant/nantcontrib? [英] IIS site and nant/nantcontrib?

查看:104
本文介绍了IIS站点和nant/nantcontrib?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以使用NAnt管理IIS Web应用程序? 例如停止还是启动它?

is it possible to manage IIS web applications with NAnt? For example stop or start it?

推荐答案

也许您可以使用执行任务来执行

Maybe you can use exec task to execute

iisreset -stop
iisreset -start

EDIT : And this VBS might help for stopping/starting WebApplications under IIS

这是在IIS上停止带有nant任务的网站的一种可行解决方案:

Here is the accespted solution to stop a website with nant task on IIS :

<target name="stopSite"> 
  <exec program="cscript.exe"> 
    <arg value="C:\windows\system32\iisweb.vbs" /> 
    <arg value="/stop" /> 
    <arg value="test" /> 
  </exec> 
</target>

这篇关于IIS站点和nant/nantcontrib?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆