Run a build on Warewolf in 3 simple steps

Warewolf can now run builds! Simply deploy the build workflows from the Warewolf Shared Resources Server hosted on http://store.warewolf.io:3142 and run the example build to try it out for yourself.

In this video I demonstrate the 3 simple steps to running the example build. This build includes pre-built interfaces to compile with Visual Studio, run tests with Visual Studio test runner and get source code with Git.

Getting set up to run a build

These interfaces expect the following software to be installed:

1. Git with support for Windows Command Prompt – This can be downloaded from http://git-scm.com/download/win

Use Git from the Windows Command Prompt

 

2. Visual Studio 2012, 2013 or 2015 for compiling and running tests.

How to run a build on Warewolf

This video is best viewed in full screen, make sure you have your sound turned on.

 

Warewolf build agent and controller architecture

In the Shared Resources Server, the build workflows are divided up into 3 folders.

1. Build Agent

The entry point workflow that exposes these workflows to a default build is the Default Build Process Template:Build agent diagram to run a build on Warewolf

2. Build Controller
  1. The entry point workflow that exposes these workflows to a default build is QueueBuild.
  2. This workflow manages a log file that:
    1. Waits in a queue.
    2. Is written to by the build agent while the build is running.
    3. Is moved to a completed builds folder.
Examples/Run an Example Build:
  1. The entry point to running the example build is Run an Example Build\Event Handler.
  2. Writes a trivial C# solution which includes 10 trivial tests one of which fails.
  3. Creates a local git repository which the example build pulls from.
  4. Creates an HTML build controller UI.

How to create a build definition and event handler

To create a build definition:

  1. Open Warewolf and create a new workflow.
  2. Drag on the Default Process Template from the Build Agent folder.
  3. Drag on a data connector for where your build definitions are stored or just drag on a multiassign tool and enter the definition data into it manually or you could even hard code the values into the input of the Default Build Process Template.
  4. Ensure the data is being passed into the Default Build Process Template is correct by debugging.
  5. You will probably have to set the User Email as an input if you are not the only one who will trigger builds.
  6. You will have to set the ChangesetID to input if you are planning to include this build in a CI process (use “latest” to use the latest version, if you do this you must specify a branch).

To create a build event handler:

  1. Open Warewolf and create a new workflow.
  2. Drag on the QueueBuild workflow from the Build Controller folder.
  3. Drag on a data connector for controller data (like the error handling server, alerts, notification settings) or just drag on a multiassign tool and enter the definition data into it manually or you could even hard code the values into the input of the QueueBuild workflow.
  4. Ensure the data is being passed into QueueBuild correctly.
  5. You will probably have to set the User Email as an input if you are not the only one who will trigger builds.
  6. You will have to set the ChangesetID to input if you are planning to include this build in a CI process (use “(latest)” to use the latest version, if you do this you must specify a branch).
  7. This event handler is either run manually, scheduled to run nightly with the Warewolf task scheduler or triggered by a GitHub web hook (this would require you to forward the Warewolf default port 3142)

If you’ve got any questions post them in the comments section below or in the Community Forum.

FacebookTwitterLinkedInGoogle+RedditEmail

Leave A Comment?