导入/导出的TeamCity构建配置从一台服务器到另一个 [英] Import/Export TeamCity build configuration from one server to another

查看:2369
本文介绍了导入/导出的TeamCity构建配置从一台服务器到另一个的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

什么是从一台服务器移到一个单独的TeamCity构建配置到其他的最好方法?

What's the best way to move a single TeamCity build configuration from one server to another?

我有TeamCity的本地实例,我测试基础上。然后,当构建已足够成熟,我手动我们主要的TeamCity服务器上创建它(眼球复印件)。

I have a local instance of TeamCity that I test builds on. Then when the build is sufficiently mature, I manually create it (eyeball-copy) on our main TeamCity server.

是否有一个出口与放大器;导入功能,它会为我做到这一点?

Is there an Export & Import feature that will do this for me?

推荐答案

不幸的是,没有这样的事情。 TeamCity的8通过引入版本ID格式(项目名称+打造的配置名称,可以覆盖),使得它为手抄可行的生成配置使情况稍微好一点,但:

Unfortunately there is no such thing. TeamCity 8 made the situation a little bit better though by introducing a Build Id format (project name + build config name, can be overwritten) that makes it feasible to "hand copy" build configurations:

基本上引擎盖下的所有的TeamCity构建配置是真正的BuildServer \\设置\\项目\\文件夹和子文件夹只是XML文件。虽然我没有试过,你应该能够把刚才复制项目文件夹或建立XML配置到您的新的TeamCity实例相应的目的地,如果IDS不会冲突。至少,你绝对可以覆盖现有项目的更新这种方式(这是我在过去做动态改变对飞打造CONFIGS)。

Basically under the hood all your TeamCity build configurations are really just XML files in the BuildServer\config\projects\ folder and sub folders. While I haven't tried this you should be able to just copy your project folder or build config XML to the appropriate destination on your new TeamCity instance if the ids don't collide. At the very least you can definitely overwrite existing projects with updates this way (something I have done in the past to dynamically change build configs "on the fly").

当然,如果你的构建配置依赖于其他构建/器物这些ID必须匹配一样,所以要么你必须复制那些和或调整相应的标识。同样适用于代理的要求。

Of course if your build config depends on other builds / artifacts those ids have to match as well, so either you have to copy those as well or adjust the ids accordingly. Same goes for agent requirements.

编辑:

使用TeamCity的9个现在有一个更好的选择移动内置的TeamCity服务器之间的项目:

With TeamCity 9 out now there's a much better option to move projects between TeamCity servers built in:

现在的TeamCity提供服务器之间移动项目的能力:您
  可与所有的数据传输工程(设置,构建和
  改变历史等),并与来自一个你的TeamCity用户帐户
  服务器到另一个。所有你需要做的是建立一个通常的备份文件
  包含项目源的TeamCity服务器需要进口,放
  备份文件插入/进口目录
  在目标服务器,并按照管理的导入步骤|
  项目导入页面。

Now TeamCity provides the ability to move projects among servers: you can transfer projects with all their data (settings, builds and changes history, etc.) and with your TeamCity user accounts from one server to another. All you need to do is create a usual backup file on the source TeamCity server containing the projects to be imported, put the backup file into the /import directory on the target server and follow the import steps on the Administration | Projects Import page.

有关的完整摘要请参见什么TeamCity的9 是新的。

For a full summary see what's new in TeamCity 9.

这篇关于导入/导出的TeamCity构建配置从一台服务器到另一个的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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