-
-
Notifications
You must be signed in to change notification settings - Fork 2
Installing Hudson Jenkins On Windows
Note: This page contains old documentation from 2011, but may still be helpful. And it would still be okay to update, correct, and add to this page.
Here are some links to get you started with Jenkins:
http://wiki.jenkins-ci.org/display/JENKINS/Meet+Jenkins
http://wiki.jenkins-ci.org/display/JENKINS/Installing+Jenkins+as+a+Windows+service
You want to install it as a windows service. I don't think you have to install a slave as a windows service if you want to build on the same machine, the master has a build executor built in (but I might be wrong since it's been a while since a experimented with this).
I suggest you install the following plugins:
- Jenkins Build-Publisher plugin (required for pushing build results to another Hudson instance)
- Jenkins build timeout plugin (required to abort hanging builds)
- Dashboard View (optional, allows you to create different views, e.g. for installer builds, release builds etc)
- Jenkins disk-usage plugin (optional, shows the amount of disk space a project uses)
- Email-ext plugin (for notification of failing builds; has more configuration options than the built-in one)
- Instant Messaging Plugin (required by IRC plugin)
- IRC Plugin (for notification on IRC channel \u266flsdevlinux-status)
- Jenkins Locks and Latches plugin (I have this installed to prevent building multiple branches at the same time on the same machine. At least in the past it didn't work if you tried to build WW branch while a build of FW trunk was going on because of the registration of COM objects. This might have changed with the refactoring - haven't tried it since)
- Jenkins NAnt Plugin (required for build)
- Node Name plugin (optional; column showing the node name that can be configured in views)
- Jenkins NUnit plugin (required to process NUnit build results)
- Perforce Plugin (required for build)
- Jenkins Radiator View plugin (optional, allows to configure a high visibility view that shows the status of the projects, see http://wiki.jenkins-ci.org/display/JENKINS/Radiator+View+Plugin for a screenshot)
- Sectioned View plugin (optional, allows structuring a view a little better)
- Jenkins Setenv plugin (I have this installed on Linux, not sure if we need it on Windows)
It is advisable to specify some labels for build executor nodes. This allows to better specify where a job should run, e.g. to make sure that a Windows job only starts on a Windows node.
- on the Jenkins main page, click on "Build Executor Status"
- click each node and go into the "Configure" page
- Specify one or more labels (separated by spaces), e.g. "Windows 32-bit Dallas"
Required and suggested global settings (in Manage Jenkins/Configure System):
- environment variables: checked
- name: localsys-workaround
- value: true
- name: VSVERSION
- value:
- define a lock for FieldWorks. This allows to prevent multiple concurrent builds of FieldWorks on the same machine.
- name: FW
- Public Hudson server:
- Name: Calgary Jenkins
- URL: http://
- Login: <username></username>
- Password: <password></password>
- check Enable IRC Notification
- Hostname: irc.freenode.net
- Port: 6667
- Channels: #LSDevLinux-status
- Under "Advanced":
- Nickname: (I suggest using a descriptive name here, e.g. dallas or waxhaw)
- Command prefix: (see email)
You can add a new project by clicking the "New Job" link on the left side. We probably should use a descriptive name that tells the platform, branch and whether it's a debug or release build, so I'd suggest naming it according to the following template: FW-<platform></platform>-<branch></branch>-<debug|release></debug|release>-<location></location>, e.g. FW-Win32-WW-debug-Dallas. If we have specialized targets we can append to the end, e.g. FW-Win32-WW-release-Dallas-installer
The following settings work for me:
You might want to restrict where this job can be run so that it doesn't try to run on a Linux node. This is especially important when publishing the build results.
- Restrict where this project can be run: checked
- Label Expression: Windows
- Perforce:
- Path to p4 executable: C:\Program Files\Perforce\p4.EXE
- P4PORT: src.sil.org:1934
- Username: anonymous
- Password: (empty)
- Workspace (client): hudson-ww-win (should probably add the location to that, i.e. hudson-ww-win-dallas)
- Let Hudson Manage Workspace View: checked
- Clean Workspace Before Each Build: unchecked
- View: //depot/WW/... //hudson-ww-win/...
- Options: noallwrite clobber compress locked nomodtime rmdir
- Poll SCM: checked
- Schedule:
# every 5 minutes */5 * * * *
- Abort the build if it's stuck: Timeout minutes: 60
- Locks:
- Name: FW
- Execute Windows batch command:
- Command:
PATH=%WORKSPACE%\Bin;%PATH% cd Bld set AssertUiEnabled=false ..\Bin\nant\bin\nant -t:net-3.5 -D:localsys-workaround=True remakefw-hudson
- Record fingerprints of files to track usage: checked
- Files to fingerprint: Output\idhfiles.MD5
- Archive the artifacts: checked
- Files to archive: Output/Debug/NUnit-report.html
- Publish NUnit test result report: checked
- Test report XMLs: Output/Debug/*-results.xml
- Publish build: checked
- Public Hudson instance: Calgary Jenkins
- Publish unstable builds: checked
- Publish failed builds: checked
- IRC Notification: checked