Simple Guide to continuous integration of teamcity + SVN + visualstudio

Source: Internet
Author: User

Continuous integration of teamcity + SVN + visualstudio

Concise Guide

 

I. Preface:

1. The component versions are as follows:

Teamcity (TC) version: 8.1.4

SVN version: tortoisesvn 1.8.7

Vs version: vs2010. 10.0.30319.1

2. CI (continuousintegration, continuous integration ):

Its importance and key are needless to say. It is skipped because it is not the focus of this article. Can refer to: http://en.wikipedia.org/wiki/Continuous_integration (concept) and http://en.wikipedia.org/wiki/Comparison_of_continuous_integration_software (CI tool comparison)

 

Ii. Installation

The installation process is not detailed. you can install it in wizard mode by clicking Next. Note that:

1. TC external service port. It is best not to use port 80 (because it is often used ). Here, I changed it to port 60380.

 

Remember two things after installation:

A. TC service link address: http: // localhost: 60380 (for cross-network access, change localhost to IP address during access)

B. TC's working directory: C: \ teamcity \ buildagent \ work (TC will checkout the code to this directory)

 

After the installation is complete, the browser is automatically opened to enter the Web UI page.

 

Iii. Use

1. The setting Wizard will pop up for the first time. It should be noted that in database settings, although TC recommends other types of databases modestly, its internal HSQLDB database can work well from our practice, therefore, we recommend that you use this database directly (which saves the trouble of configuring external databases ). Use the default value for other settings.

2. After the Web UI page Initialization is complete, register a user, and then log on with the user

After logging in, we can see that a TC proxy server already exists.

3. Create a project. Click "Create Project" and fill in the following elements to create a project.

 

4. Create compilation Configuration

4.1 In general settings, click Create build configuration.

4.2 create compilation Configuration

4.3 Create Code Manager attributes

Select the VCs type (SVN is used in the example, and other code management software configurations are similar) to complete the Code Manager attribute configuration. (The IDE used in this example is vs2010. Therefore, the URL in the svn connection settings attribute selects the directory where the solution (. sln) is located)

After the configuration is complete, the test connection passes successfully.

4.4 set the finished path

/Subprj1/bin/release/Win32/*. EXE =>. \ testsln \ subprj1 \ release \ Win32 \

Note: Copy all files with the extension .exe under the directory (/subprj1/bin/release/Win32/scripts) of the VS solution. \ testsln \ subprj1 \ release \ Win32 \ directory c: \ programdata \ jetbrains \ teamcity \ System \ artifacts \ silkwaysvn20140521)

4.5 set compilation steps

Click buildsteps on the left and configure the runner. (The example uses the vs runtime environment)

At this point, you can click the run button in the upper right corner to perform the integration compilation test.

Then, go to the TC working directory to check the compilation and generation. (You can view the TC checkout directory by building logs)

4.6 set a trigger

The purpose of setting a trigger is to automatically compile and integrate the Trigger Based on the condition.

Add new trigger

Select a VCs trigger. For example, if you select "trigger a build on eachcheck-in", you can set it to compile every code migration. Other common settings include daily scheduled compilation and other options.

 

Simple Guide to continuous integration of teamcity + SVN + visualstudio

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.