Setting up from scratch Part 01

简介: 原文:http://confluence.public.thoughtworks.org/display/CCNET/Setting+up+from+scratch++Part+01   Added by Ruben Willems , last edited by Rube...

原文:http://confluence.public.thoughtworks.org/display/CCNET/Setting+up+from+scratch++Part+01

 
Added by Ruben Willems , last edited by Ruben Willems on Sep 29, 2007  (view change)

We'll be setting it up step by step, so this will be a real step by step approach. The reason is you can see what the benefits are of the setups used in this document.
The first parts will seem overdone for users who used CCNet before, but it is intended for the real starters. Later parts contain tips/situations for people with the basic knowledge.

Typically a build system consists of 2 servers and X development machines, they can be on different physical machines, but they can also be hosted on 1 machine.
Or 1 physical machine with virtual machines on it, everything is possible

These 2 servers are :   
° Build server  : referenced as BuildServer
° Source Control server : referenced as SourceControl

For this example the setup will be on 1 machine, so everybody can follow this tutorial without having to maintain multiple PC's.

The easiest way to set things up is to respect the following installation order :
° windows
° IIS
° .Net framework
° Visual Studio
° extra tools (Nant, Testdriven.Net, NCover, ...)

Step 1 : Installing CCNet

Since it has an installer, it is in fact : setup, next, next, next, ...
Once this is done, you will have :
° a new folder in \Program Files : CruiseControl.Net
° a shortcut on the desktop : CruiseControl.Net
       This shortcut will start the build server.

Step 2 : Folder structure

Make the following folders

Folder Name Purpose
c:\Integration will contain the integration logs, artifacts, sources, ...
c:\Repository will contain the repository of our source control
c:\Projects will contain checked out sources to work with


note : this is not the best folder structure for sources, but for these example it will do fine.
          for setting up development trees, see Tree Surgeon (http://www.codeplex.com/treesurgeon),  CIFactory (http://www.cifactory.org/joomla), ...




 

Step 3 : First basic CCNet project

This project is just for playing around a bit with cruisecontrol, without having to do any real coding.
We'll just use a batch file, and play a bit with that.
Make a subfolder in c:\projects, named Example01
Create a command script named 'test.cmd' with the following contents

@echo off
set

 

If you run this script, you'll see all the environment variables of your machine.

Step 4 : Configuring the build server

Start the build service, (there is a desktop icon) you will see a command window wit the following :

[CCNet Server:DEBUG] The trace level is currently set to debug.  This will cause CCNet to log at the most verbose level,
which is useful for setting up or debugging the server.  Once your server is running smoothly, we recommend changing
this setting in C:\Program Files\CruiseControl.NET\server\ccnet.exe.config to a lower level.
[CCNet Server:INFO] Reading configuration file "C:\Program Files\CruiseControl.NET\server\ccnet.config"
[CCNet Server:INFO] No projects found
[CCNet Server:INFO] Registered channel: tcp
[CCNet Server:INFO] CruiseManager: Listening on url: tcp://192.168.131.72:21234/CruiseManager.rem
[CCNet Server:INFO] Starting CruiseControl.NET Server



Since there are no projects, we'll add one for this simple script. Leave the CCNet server running, it will pick up the changes to the config file after every save.
Modify CCNet.config, found in \program files\CruiseControl.Net\server
Enter the following text :
<cruisecontrol>
    <project>
        <name>SimpleExample</name>

	<triggers />

	<tasks>
	    <exec>
		<executable>c:\projects\test.cmd</executable>
	    </exec>
	</tasks>
    </project>
</cruisecontrol>

 

You'll see that the command window of the server added the following lines.

[680:INFO] Configuration changed: Restarting CruiseControl.NET Server
[680:INFO] Reading configuration file "C:\Program Files\CruiseControl.NET\server\ccnet.config"
[SimpleExample:INFO] Starting integrator for project: SimpleExample


 

Now you can also browse to the dashboard,

open your browser and surf to http://localhost/ccnet
you will see the project : SimpleExample

Press the 'Force' button to force the build. Next press 'Refresh Status' to view the result.

You see that the build was successfull

Clicking on the project name 'SimpleExample' will show a page with project related information. From there on you can go to individual builds.

This shows how to set up a very basic project in CCNet, the next topic will cover :

° improving the project setup
° setting up source control monitoring
° getting information about builds

相关文章
|
1月前
|
网络安全 Python Windows
pyspark--完美解决 Could not find a version that satisfies the requirement 安装包名字 (from versions: )
pyspark--完美解决 Could not find a version that satisfies the requirement 安装包名字 (from versions: )
99 9
|
TensorFlow 算法框架/工具 异构计算
成功解决PackagesNotFoundError: The following packages are not available from current channels: tensorflo
成功解决PackagesNotFoundError: The following packages are not available from current channels: tensorflo
成功解决PackagesNotFoundError: The following packages are not available from current channels: tensorflo
|
11月前
使用parted创建大分区时 mkpart Warning: The resulting partition is not properly aligned for best performance.
fdisk不能创建大于2T的分区,创建大分区得用parted,我在用parted创建分区时遇到下面的警告提示
169 0
|
11月前
PackagesNotFoundError: The following packages are not available from current channels:
PackagesNotFoundError: The following packages are not available from current channels:
78 0
|
开发工具 git
报错解决:your local changes to the following files would be overwritten by merge: .idea/workspa
报错解决:your local changes to the following files would be overwritten by merge: .idea/workspa
361 0
报错解决:your local changes to the following files would be overwritten by merge: .idea/workspa
|
开发工具
Warning! This package referenced a Flutter repository via the .packages file that is no longer avail
Warning! This package referenced a Flutter repository via the .packages file that is no longer avail
104 0
Warning! This package referenced a Flutter repository via the .packages file that is no longer avail
SAP WM中阶Storage Type的Capacity Check – Usage check based on material
SAP WM中阶Storage Type的Capacity Check – Usage check based on material
SAP WM中阶Storage Type的Capacity Check – Usage check based on material
Cannot find source code based button in SE24 - modification assistant
Cannot find source code based button in SE24 - modification assistant
127 0
Error This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, se
错误提示: Severity Code Description Project File Line Suppression StateError This project references NuGet package(s) that are missing on this computer.
994 0
Choosing Partners and Scenarios in a Multi-cloud World
From the minute you chose one of the world’s most popular cloud computing companies as your strategic cloud services provider, your world moved on to multi-cloud.
1643 0