为什么我不能在我的CI服务器上安装Visual Studio? [英] Why ought I not to install Visual Studio on my CI server?

查看:207
本文介绍了为什么我不能在我的CI服务器上安装Visual Studio?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

很多新的CI(持续集成)在他们的CI服务器上安装VS(Visual Studio),因为它需要编译代码。 MSTest是这里提出的一个常见参考。

A lot of people new to CI (Continuous Integration) install VS (Visual Studio) on their CI server "because it is required to compile the code". MSTest is a common reference brought up here.

为什么我不能在我的CI服务器上安装VS(或一般来说,不是开箱即用的软件) ?

Why should I not install VS (or generally speaking, any software not out-of-the-box) on my CI server?

(这个问题在明显之前没有被提出过,所以我将其添加为参考,如果它已经存在,对不起,我错过了,请合并。

(This question has not been asked before apparently, so I'm adding it for reference. If it already exists, sorry, I missed it, please merge. If no answer is provided to this question within some time I can add one myself)

推荐答案

因为你不需要到。 Visual Studio许可证是相当昂贵的,所以有一个只是躺在一个服务器上,没有人使用它只是一个浪费。有几个参数,为什么你仍然需要安装一个完整的Visual Studio实例在连续集成服务器 - 但这里是他们的计数参数:

Because you don't need to. A Visual Studio license is pretty expensive, so having one just lying around on a server where no one's using it is just a waste.There are a couple of arguments why you would still need to install a full blown Visual Studio instance on your Continuous Integration server - but here are their counter arguments:

原因1:我需要它来编译。

现实: ,你不会。您需要 MSBuild 进行编译,但这是免费,在Windows SDK中。请注意,对于不同的操作系统和.NET版本,有几个版本,所以请小心下载正确的版本。

Reason 1: I need it to compile.
Reality: No, you don't. You need MSBuild to compile, but that is available for free, in the Windows SDK. Note that there are several versions for different operative systems and .NET versions, so be careful to download the correct one.

原因2:在服务器上快速修复。

现实:不,你不是。您不应该在服务器上进行快速修复 - 您应该从版本控制系统检出,在本地进行修复,构建和运行测试,直到它工作,签入并让CI系统执行其余为你。 这是为什么你有一个CI系统。

原因3:没有Visual Studio,我不能运行MSTest没有我的CI服务器。

现实:错误。 AFAIK,MSTest运行器也是SDK的一部分(至少这是我们的CI服务器上的似乎是什么 - 虽然我不能验证它,因为我们目前还没有任何测试...)。但是,此博文中会介绍如何进行快速搜索它没有SDK也是如此。我没有详细阅读它,所以我不能保证它的工作,或者它是合法的。您已收到警告。

Reason 3: Without Visual Studio, I can't run MSTest no my CI server.
Reality: Wrong. AFAIK, the MSTest runner is also part of the SDK (at least that's what it seems like on our CI server here - although I can't verify it since we don't have any tests at the moment...). However, a quick googling found this blog post which explains how to do it without the SDK as well. I haven't read through it in detail, so I can't promise that it works, or that it's legal. You have been warned.

随意在评论中添加更多原因,我会予以处理。

Feel free to add more reasons in comments, and I'll counter them.

这篇关于为什么我不能在我的CI服务器上安装Visual Studio?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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