Jenkins Library for Unreal Engine 4

🔖 game-development ⏲️ 1 minute to read

⚠️ This post was last updated in 2021, meaning its contents may be outdated.

For Estranged: The Departure, I released on Steam many hundreds of times, all at the push of a button using a tool called Jenkins.

At its core, Jenkins is a job scheduling system, where a job consists of some commands to run. You can define the job in the Jenkins interface or, as I prefer, in a Jenkinsfile which lives at the root of your source control repository.

I won't explain how to get a Jenkins server and attach a Windows build machine to it as there are better resources out there to explain that:

This post outlines the general-purpose Jenkins library I developed for Estranged. The library can be found here:

Building Estranged

The README in the repository does a pretty good job of going over the options, but here is the build script for Estranged. First, we need to obtain the library, load it, and set some variables for use further down:

def builder;
dir ('Builder') {
    git(url: '', branch: 'v1');
    builder = load('UnrealEngine.groovy');

String enginePath = env.UnrealEngine424;
String projectPath = env.WORKSPACE + '/Depot/Insulam.uproject';
String targetPlatform = 'Win64';

Then we can check out the game (not shown), and use the builder to build the Editor binaries:

And then cook and package the game:

def buildResult = builder.buildCookRun()
    .archiveDirectory(env.WORKSPACE + '/Packaged')

Finally we extract the debugging symbols:

    .symstore('C:\\Program Files (x86)\\Windows Kits\\10\\Debuggers\\x64\\symstore.exe')
    .destination(env.WORKSPACE + '/Symbols')

The debugging symbols can be uploaded to a symbol server, or something like Amazon S3 (I use CloudFront + S3). The game in buildResult.deployPath can now be deployed to a storefront like Steam.

Other Features

The library also wraps the "resave packages" functionality of the Unreal Engine 4 Editor, which allows you to run lighting builds, reflection captures and all kinds of other computational tasks. The example below builds lighting for the specified maps, and updates the reflection captures:


This could run lighting builds at weekends for example and check them into source control.

All options can be found on the README.

🏷️ jenkins library estranged source game symbol light unreal engine steam repository windows machine step readme

⬅️ Previous post: Three Approaches to Readable Materials in First Person Games

➡️ Next post: Spotting Fake Indie Game Key Requests

🎲 Random post: Optimising Rocket Chat Content Delivery with CloudFront


Please click here to load comments.