You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/processes/continuous_integration/Adding-a-new-Windows-machine-to-Jenkins.md
+71-31Lines changed: 71 additions & 31 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,34 +1,87 @@
1
-
# Adding a new Windows machine to Jenkins
1
+
# Adding Jenkins nodes
2
2
3
3
These are instructions for adding a new Windows machine as a node to be used by Jenkins.
4
4
5
-
### Initial Preparation
5
+
## Hardware Prerequisites
6
+
7
+
A useful build server will need roughly the following specifications:
8
+
- Processor:
9
+
- Not a virtual machine (we have tried VMs in the past, but the performance penalty is too high for a
10
+
build server)
11
+
- Semi-modern processor. Most of our builds are _primarily_ single-threaded, so single-core performance
12
+
is more important than multicore at present.
13
+
- Memory:
14
+
- 32GB or more of RAM (16GB may be possible to use, but will be substantially slower to build). Extra RAM
15
+
can be acquired relatively cheaply, if the machine has spare memory slots (check compatibility carefully).
16
+
- Storage
17
+
-**Must be an SSD**. PCIe (M.2) preferred but not required. Do not use a spinning hard disk as a build drive - it will be painfully slow.
18
+
- Doesn't need to be the primary OS drive - a separate drive also works and can generally be acquired relatively cheaply, if the machine has a spare M.2 or SATA port.
19
+
-**For an EPICS build node**: 1TB capacity minimum. This capacity is needed because multiple builds' workspaces will be present at once.
20
+
-**For a system tests build node**: 500GB capacity minimum.
21
+
- Location
22
+
- The machine should be located in a suitable place, ideally in a room with air-conditioning. Many of our
23
+
build servers are in the R55 server room for this reason.
24
+
25
+
## Software Prerequisites
26
+
27
+
It is possible to follow the "full" first-time install guide to get all the components necessary for build jobs:
6
28
7
29
* First set up the machine so it can be used to build the back-end system manually by following these [instructions](/overview/First-Time-Build)
8
-
9
30
* After you have registered the ISISICP go into `c:\Instrument\Apps\EPICS\ICP_Binaries\isisdae` and read `README_isisicp_reg.txt` in particular you will probably need to add the the account running jenkins to the windows group mentioned
10
-
11
31
* Delete the EPICS subdirectory that was created in the previous step (maintaining C:\Instrument\Apps)
12
32
13
-
### Adding to Jenkins
14
-
15
-
* Go to https://epics-jenkins.isis.rl.ac.uk/computer/ and log in to Jenkins
16
-
33
+
### EPICS build node
34
+
35
+
The bare minimum requirements for an EPICS/GUI/Uktena build node are:
The bare minimum requirements for a system tests node are:
53
+
54
+
- Create directories:
55
+
*`c:\Instrument\Apps`
56
+
*`c:\Instrument\var\autosave`
57
+
*`c:\Instrument\var\logs`
58
+
*`c:\Instrument\var\tmp`
59
+
- Java
60
+
- git
61
+
- Latest MySQL (use `upgrade_mysql` script in `ibex_utils`)
62
+
- Ensure there is a config directory for this instrument, in `C:\Instrument\Settings\config\<machine name>`
63
+
* Must be checked out onto an instrument branch
64
+
- Ensure there is a calibrations directory for this instrument, in `C:\Instrument\Settings\config\common`
65
+
* Must be a git checkout, on `master` branch
66
+
67
+
## Adding to Jenkins
68
+
69
+
* Go to [our jenkins instance](https://epics-jenkins.isis.rl.ac.uk/computer/) and log in to Jenkins
17
70
* Create a `New Node` with the Node Name as the computer name, select 'Permanent Agent'
18
-
19
-
* Set a root directory of C:\Jenkins
20
-
21
-
* Set a label of 'windows'
22
-
71
+
* Set a root directory of `C:\Jenkins`
72
+
* The root directory may need to be on a different drive, if the `c:\` drive is small. See hardware prerequisites
73
+
above, for minimum hardware requirements of this drive.
74
+
* Set labels
75
+
- For an EPICS build node, create **two** build nodes in Jenkins
76
+
* One called `<computer_name>`, with the following labels: `ConfigCheck genie gui isisicp`, with 4 executors.
77
+
* One called `<computer_name>_epics`, with the `epics_build` label, with a single executor.
78
+
* For a system tests build node, create a single Jenkins node, with label `system_tests`, with a single executor.
23
79
* Select the `Launch agent by connecting it to the controller`
24
-
25
80
* Save
26
-
27
81
* Select the slave that has just been created and make a note of secret. For an initial test make a note of the curl and java commands from `Run from agent command line: (Windows)`
82
+
* In a command window in c:\jenkins run the curl and java commands. These can be put into a bat file for interactive running.
28
83
29
-
* in a command window in c:\jenkins run the curl and java commands. These can be put into a bat file for interactive running.
30
-
31
-
## setup as service
84
+
## Setup as service
32
85
33
86
We use https://github.com/jenkinsci/windows-slave-installer-module and https://github.com/winsw/winsw the relevant files are in
34
87
`\\isis\shares\ISIS_Experiment_Controls_Public\third_party_installers\latest_versions\builderserver` to copy to `c:\Jenkins`
@@ -43,16 +96,3 @@ Open an admin cmd window and run `jenkins-agent.exe install` and then `servies.m
43
96
Find the jenkins service in the Service Manager window on the machine, and change it to run as `isis\ibexbuilder` rather than local service account, you'll need to enter `ISISBuilder` password.
44
97
45
98
Then run start service from the Service Manager window.
46
-
47
-
### configure jenkins-agent.xml
48
-
49
-
We need a longer git checkout time than default of ten minutes. To adjust for submodule operations see https://plugins.jenkins.io/git/#plugin-content-default-timeout which basically means you need to add `-Dorg.jenkinsci.plugins.gitclient.Git.timeOut=60` to both the jenkins server and the client args. On the java command line put it before the `-jar` option as otherwise it gets passed as an argument to the jar file
50
-
51
-
<aname="jenkins_gui_tests"></a>
52
-
### Special Notes on Jenkins for GUI Tests
53
-
54
-
The GUI test currently run on NDWRENO. The test behaviour is different when Jenkins is running as a service, so instead it is run as a command from a batch file. The batch file is located on the desktop for the user builder. On first start up this shows running in a console Window, but this is unintentionally hidden the the system tests. (I am not sure that this is true anymore - John)
55
-
56
-
In case NDWRENO goes offline the command to run the slave is also shown at [http://epics-jenkins.isis.rl.ac.uk/computer/ndwreno/](http://epics-jenkins.isis.rl.ac.uk/computer/ndwreno/).
57
-
58
-
System tests need the RCPTT plugin this is downloaded from here (http://www.eclipse.org/rcptt/download/), currently on 2.1.0. Once downloaded extract them to C:\Jenkins\RCPTT_Runner (set in runner.cmd). The current version appears to need java 1.8 and because the instrument add the latest JDK you need to install JDK 1.8. The version of java that jenkins slave uses is set in `jenkins-clas.xml` in `c:\jenkins`.
0 commit comments