How can I specify another server to copy the build files onto?

若如初见. 提交于 2019-12-13 01:14:43

问题


I'm trying to create a MSBuild script for running in TeamCity. I have a problem when I want to copy the files generated by the Project Build to another server. I tried to map that server as X:\ but I got the error that it can't find that path. Can anybody help me? Thanks


回答1:


Drive mappings can be problematic to use from build scripts. It would be better if you can use a network share. If not you may have to use a tool like MSDeploy.




回答2:


Like David commented above, you need to run the Teamcity Agent service as the user that has the drive mapped. To do that, go to the Services console, right click the service "Teamcity Build Agent", Properties, Log On, This account.

What I usually do is to use UNC path and if needed, before reaching the path I authenticate with "net use \machine\folder /USER:domain\user password".



来源:https://stackoverflow.com/questions/2645209/how-can-i-specify-another-server-to-copy-the-build-files-onto

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!