官术网_书友最值得收藏!

Installing on Windows

Installing TeamCity on Windows is straightforward when using the setup package. The package includes both the server and the agent and provides the option to install either of them or both. The installation package can be downloaded from http://www.jetbrains.com/teamcity/download/.

Note

TeamCity is a Java-based product and hence requires Java Runtime Environment (JRE). The TeamCity installation package for Windows comes bundled with JRE 1.7 and the Tomcat 7 servlet container. This is recommended and is the easiest way to install TeamCity's server and agent on Windows.

Installing the server and the default agent

The steps involved in installing TeamCity using the installation package are as follows:

  1. Double-click on the downloaded setup exe file. It should bring up the installation wizard like any other setup file on Windows. Accept the license and proceed to the next step.
  2. The next step in the wizard is to choose the installation directory. This is where the TeamCity server (and agent) will be installed. The default directory is C:\TeamCity. We will be calling this <TeamCity Home directory>.
  3. Since the package includes both the server and the agent, the next step asks you to choose the components to be installed. You can choose to install the server, the agent, and also choose whether Windows services need to be set up for each of these components. It is recommended that you set up the server and the agent as services.
  4. Next, you will have to choose <TeamCity Data directory>. This is the path where TeamCity will store its configuration, build history, users, and other data. The default for this is %ALLUSERSPROFILE%\JetBrains\TeamCity.

    Note

    Since <TeamCity Data directory> stores all of the data, including the artifacts, it is ideal to have this on a big enough drive, but not on the system drive. You can learn more about the data directory at http://confluence.jetbrains.com/display/TCD8/TeamCity+Data+Directory.

    This step also sets the TEAMCITY_DATA_PATH environment variable to the path that you set in the wizard.

  5. Continuing on, the installation copies the files and sets up TeamCity. The next bit of configuration that needs to be set is the port for the server. The default is 80.

    Tip

    Port 80 may be used by other applications, including IIS, so it is not ideal to use this port, unless you definitely want to do so.

  6. If you choose to install the agent, next comes the Configure Build Agent Properties screen. The following screenshot shows this screen for a typical installation:

    As seen in the previous screenshot, this screen allows you to view and edit various agent configurations. This includes the name of the agent, the port through which it communicates with the server, and the working directory of the agent. The defaults should be ideal for most setups. You may want to ensure that the firewall doesn't block the agent port (default 9090). These properties are saved at <Installation Directory>\buildagent\conf\buildAgent.properties.

  7. If the server and the agent are being installed as Windows services, the next steps will ask you to choose between a local system account and a specific user account for them. It is recommended that you use a specific user with enough but limited rights for the services. The wizard also provides you with the option to start the services then and there. The user under whom the server service is running should have the following rights:
    • Write permission to <TeamCity Data directory>
    • Write permission to <TeamCity Home directory>
    • Right to log in as a service
  8. The TeamCity web interface should open up with the TeamCity First Start page.
  9. The first time installation asks you to agree to the license from the web interface, and you can opt to send usage statistics to the developers. You are also asked to set up the initial administrator account after which the TeamCity server should be ready for use.

    Tip

    The steps are accurate for TeamCity 8.0.4. The exact steps may change in future versions, but the general process is expected to be the same.

Installing additional agents

Additional agents can be easily installed from the Agents page:

http://<serverUrl>:<serverPort>/agents.html

The Install Build Agents link at the top-right corner of this page can be used to download the agent installer (MS Windows Installer) directly from the server. The following screenshot shows the pop up that is presented once you click on this link:

Installing an additional agent is very similar to installing the default agent using the combined installer, as described in the previous section.

Agents need to be approved from the Agents page. Agents on the same machine as the server are approved automatically, whereas any other agent must be manually approved for it to be added to the list of available agents.

主站蜘蛛池模板: 项城市| 桂阳县| 内黄县| 泰宁县| 团风县| 北海市| 秦皇岛市| 焦作市| 盐津县| 将乐县| 方山县| 连平县| 沙湾县| 寻甸| 龙陵县| 元江| 永城市| 方正县| 班玛县| 蓝山县| 都兰县| 巴彦淖尔市| 江达县| 互助| 瑞安市| 石台县| 深圳市| 三原县| 林周县| 松桃| 行唐县| 临城县| 贵德县| 民丰县| 类乌齐县| 临湘市| 茶陵县| 霍山县| 宿迁市| 太谷县| 布尔津县|