Project

General

Profile

How to trigger the standard CI build

Once the CI environment is setup (instructions are available here), you can trigger the CI build using the trigger script with a proper set of options.

The command to trigger the default CI build is

CI_CERT=/tmp/ci_cert.pem
kx509 -o ${CI_CERT}
trigger --build-delay 0 --cert ${CI_CERT}

NOTE: with current Jenkins server version it is mandatory to provide a CILogon cert to get authenticated to trigger CI builds.

The --help option provides the list of available options:

$ trigger --help
 usage: trigger [options]
   trigger build of larsoft continuous integration build.
 options:
   --help               print this message
   --debug              turn on debug prints
   --reason             set custom trigger reason
   --no-debug           turn off debug prints
   --copy-out           tell test runner to copy out reference data
   --master-url         set url to reach Jenkins build master
   --jobname            set Jenkins job name
   --revisions          give revision specification, i.e. '*@mybranch'
   --build-delay        set Jenkins build delay
   --version            specify version of lar_ci to checkout and use
   --make-tests         specify list of make test/mrb test tests (default "ALL")
   --ci-tests           specify list of post-install tests for test runner (default "default")
   --tests              short for --ci-tests
   --gen-ref-tests      specify CI test suite to use to generate reference files (default "default")
   --quals              qualifiers for the version of lar_ci
   --workflow           specify existing workflow to use from the choosen workflow config file; this is a comma separated list
   --personality        specify existing personality to use from the choosen workflow config file
   --wfcfg              specify existing workflow config file to use, relative to $LAR_CI_DIR
   --new-wfcfg          specify new custom workflow config to use
   --gridwf-cfg         specify existing grid workflow config file to use, relative to $LAR_CI_DIR; this is a comma separated list
   --scan-branches      get branches to build from local checked-out directories
   --scan-revisions     get revisions to build from local checked-out directories
   --force-platform     force the build to be executed only on the selected platform
   --parent-build       set the parent CI build that triggered the current CI build
   --build-identifier   set the build identifier
   --testmode           turn on test mode (default off)
   --export | -e        exports env var to the CI, you can use this option as many time as you need. The syntax is -e var=val
   --extra-notify       set custom extra notify application to notify commits
   --cert               cert path to trigger CI build job

Useful option of the trigger script are:

  • --build-delay
    Set the build delay in seconds to start the CI build, the default value is 900 s.
  • --revisions
    provide the revision/branch/tag to be tested for each module, you can use the "*" wildcard to specify modules. The format is "module1@rev1 module2@rev2".
    If you use the wildcard, the first pattern that matches a module is used for the revision to test. The default value is "*@develop", i.e. the develop branch for all modules
  • --quals
    set the qualifiers used for the CI build, the current default is "e17:prof", the default is always updated to reflect what is used for the current weekly LArSoft release.
  • --force-platform
    force the build to be executed only on the selected platform, supported values are:
  • slf6
  • slf7
  • d16

You can also combine them using a comma separated list.
The default value is: slf6,slf7

  • --version
    specify the version of CI to use on Jenkins to run the CI build.

Example of a trigger command

trigger --build-delay 0 --version develop \
--revisions "lariat*@v06_74_00 lar*@LARSOFT_SUITE_v06_74_00 dunetpc@feature/xy_branch sbndcode@v06_74_00_01 uboonecode@a23eds23" \
--workflow defaultwf --force-platform slf6

This CI build will build and test all the module specified by the defaultwf workflow (i.e. all LArSoft modules + all experiment code)
using the v06_74_00 tag for all modules that match the lariat* pattern,
the LARSOFT_SUITE_v06_74_00 tag for all module that match the lar* pattern,
(note: lariatsoft module matches both lariat* and lar* patterns, but it will be used the tag that correspond to first matching in the list, i.e. lariat*@v06_74_00 in this case),
the branch feature/xy_branch for dunetpc,
the branch/tag v06_74_00_01 for sbndcode,
the revision a23eds23 for uboonecode,
for all the other modules it will be used the develop branch that is the default.

This CI build will use only the slf6 platform.

An email report is sent to whom manually trigger the CI build, beside to the other mailing list(s) configured in the workflow.cfg for the specified workflow.