Permissions Nant/巡航控制-无法将文件复制到其他服务器
此Nant任务(由CruiseControl控制)无法将文件复制到另一台服务器上的共享Permissions Nant/巡航控制-无法将文件复制到其他服务器,permissions,cruisecontrol.net,nant,Permissions,Cruisecontrol.net,Nant,此Nant任务(由CruiseControl控制)无法将文件复制到另一台服务器上的共享 <target name="DeployToTargetDirectory" description="Copies files to target deploy folder (this may not be the final virtual directory)"> <if test="${not directory::exists(AppDeploymentFolder)}">
<target name="DeployToTargetDirectory" description="Copies files to target deploy folder (this may not be the final virtual directory)">
<if test="${not directory::exists(AppDeploymentFolder)}">
<fail message="Deployment folder not found: ${AppDeploymentFolder}"/>
</if>
<!--Delete existing files in deployment folder-->
<echo message="Clearing down existing files and folder in deployment folder: ${AppDeploymentFolder}"/>
<delete>
<fileset basedir="${AppDeploymentFolder}">
<include name="**/*"/>
</fileset>
</delete>
<!--Copy all files / folders to the deployment folder-->
<echo message="Copying configured site to: ${AppDeploymentFolder}"/>
<copy todir="${AppDeploymentFolder}">
<fileset basedir="${StagingFolder}">
<include name="**/*"/>
</fileset>
</copy>
我得到一个错误:
无法创建目录“xxxx”。
对路径“xxxx”的访问被拒绝
我认为这是一个权限问题,但我不知道Nant在哪个帐户下运行
我能找到这个吗
谢谢。nant运行的可能不是帐户,而是cruisecontrol运行的帐户,因为它是执行该进程的帐户。所以我要检查哪个帐户运行cruisecontrol。如果是系统帐户,您可能希望让它使用真实帐户,然后您可以授予该帐户执行所有任务所需的权限。CruiseControl在NetworkService帐户下运行。让我困惑的是,这种用法很管用,但最近刚刚停止。我假设我们的网络管理员删除了一个域帐户,但他们说没有。就我个人而言,我会将服务转换为在您控制的域帐户下运行,这样您就可以非常轻松地解决权限问题。这就是我们在农场建设中所做的。它们都在一个域帐户下运行,该帐户可以访问所有必需的部分/目的地。只需确保域帐户在运行cruisecontrol的计算机上有足够的特权,这样它也不会出现问题。