TeamCity SVN 签出由于文件锁定而失败
这是我的第一个 TeamCity 项目,我在 SVN 签出方面遇到问题。
以下是我在 TeamCity 中进行 SVN 签出的设置:
- VCS 签出模式 - 自动在代理
- 签出目录上 - C:\BuildCheckouts[项目名称]
- VCS 标签模式 - 不标记
- 外部支持 - 完全支持
- 默认配置目录 - 使用默认目录
- 工作复制格式 - 1.5
在我第一次运行构建时,一切运行良好,进行签出,然后构建继续。然而,在我第二次检查时,构建失败,并且收到以下错误消息:
[03:31:28]: Updating sources: Agent side checkout... (1s)
[03:31:30]: [Updating sources: Agent side checkout...] Failed to perform checkout on agent: org.tmatesoft.svn.core.SVNException: svn: Error during update from http://[Server Name]/svn/[Project Name] to C:\BuildCheckouts\[Project Name]
svn: Cannot create new file 'C:\BuildCheckouts\[Project Name]\Tools\.svn\lock': Access is denied
我尝试搜索此特定错误,并提出了这篇旧文章 (2003),但它似乎不适用,因为我使用的是 NTFS作为我的文件系统。
由于我的构建脚本在编译后运行测试,因此我需要将外部文件与实际代码一起下载到结帐目录。
我的配置设置不正确吗?
This is my first TeamCity project, and I am having an issue with SVN checkout.
Here are my settings for the SVN checkout from within TeamCity:
- VCS Checkout Mode - Automatically on Agent
- Checkout Directory - C:\BuildCheckouts[Project Name]
- VCS Labelling mode - Do Not Label
- Externals Support - Full Support
- Default Config Directory - Use Default Directory
- Working Copy Format - 1.5
On my first run of the build, everything runs fine, checkout occurs, and the build continues. On my second checkout, however, the build fails and I get the following error message:
[03:31:28]: Updating sources: Agent side checkout... (1s)
[03:31:30]: [Updating sources: Agent side checkout...] Failed to perform checkout on agent: org.tmatesoft.svn.core.SVNException: svn: Error during update from http://[Server Name]/svn/[Project Name] to C:\BuildCheckouts\[Project Name]
svn: Cannot create new file 'C:\BuildCheckouts\[Project Name]\Tools\.svn\lock': Access is denied
I have tried searching for this specific error, and came up with this old article (2003), but it does not seem to apply since I am using NTFS as my file system.
Since my build script runs tests after compiling, I need the externals downloaded to the checkout directory along with the actual code.
Are my configuration settings incorrect?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
尝试在有权修改计算机上文件的特定用户帐户下运行 Teamcity 服务。我们正在这样做,但尚未遇到此问题。
Try running the Teamcity service under the specific user account which has permissions to modify files on the machine. We are doing so and haven't faced this issue.
TeamCity 的构建代理在特定用户下运行(检查构建代理的 Windows 服务的设置)。
因此,该用户应该具有对 C:\BuildCheckouts 目录及以下目录的完全访问权限。
TeamCity's build agent runs under specific user (check settings of the windows service for the build agent).
So, this user should have full access to the C:\BuildCheckouts directory and below.