Content is available under Creative Commons Attribution.



A software deployment engine written in C++


Leroy is a software deployment engine designed to allow software and build/release engineers to describe the deployment of an application in plural environments with a singular workflow in xml, which is intended to be versioned in your repository as code, in the service of continuous integration.

Leroy is a fast, lean threaded tool that is written for multiple platforms in C++. It consists of two major components; the agent and the controller. The agents are run on any system you wish to perform tasks on. They do not listen on a port; instead, they reach out to the controller and wait for it to come online. The controller contains all the configuration and artifacts needed to perform a deployment to all environments and is launched on demand. Leroy provides the complete picture for continuous integration and continuous deployment, which is a requirement for agile software development. Best of all, Leroy is free to use for commercial and non-commercial use under the creative commons license.

When there is work to be done, the controller is started and accepts connections from the agents. When all the agents needed in a given environment check in with the controller, the controller issues workflow steps to the agents and receives output from the agents. This all operates in a multi-threaded fashion with synchronization controls to maximize flexibility and minimize how long deployments take.

One of the design goals of Leroy was to provide a simplified programming language to describe the deployment of an application to all environments, end-to-end in a easy to read and well-known format.

How can I use Leroy ?

Leroy allows you to add the feature of deployment automation in ANY build system. Build systems include (but are not limited to):

To initiate a deployment, one simply executes the controller executable as:

c:\Leroy> controller.exe --workflow Initialize --environment dev

or from your favorite *nix:

$/home/leroy> ./controller --workflow Initialize --environment dev

The controller will come online and wait for all agents in the dev environment to connect. Once the controller sees all the agents have reported in, the deployment begins. The controller will return 0 to the shell if the deployment is successful, and non-zero if it is not, allowing any build system to easily detect if the deployment has completed or failed.

Leroy can perform automated database deployments with:

Controller structure:

Controller Usage:

Usage: controller [--config <filename>] [--addagent <addagent-options>|--extractagent <agentName>|--extractagent-all|--ssh-install <agent-bundle> <ssh-options>|<workflow environment> {--add-*-property <KEY>=<VAL>}]

Program Options:
  --help                         This message
  --addagent                     Add a new agent to the system.
  --extractagent arg             Re-generate an agent .zip installation package.
  --extractagent-all             Re-generate .zip installation package for all agents.
  --ssh-install arg              SSH install an already generated agent.
  --workflow arg                 The workflow to run
  --environment arg              The environment to operate on.
  --environment-file arg         An optional file where environments are defined. 
                                 Default: environments.xml
  --config arg                   An optional configuration file. 
                                 Default: controller.xml
  --add-global-property arg      Add controller-global property. Can be used 0
                                 or more times. Argument format is KEY=VAL
  --add-workflow-property arg    Add property to the workflow. Can be used 0 or
                                 more times. Argument format is KEY=VAL
  --add-environment-property arg Add property to the environment. Can be used 0
                                 or more times. Argument format is KEY=VAL
  --force-agent-update           Forces agents to update, even if they are up to date.

AddAgent Options:
  --agent-platform arg    The agent platform/architecture.
  --agent-name arg        The agent name to be added in the system.
  --agent-logicalname arg The agent logical name (alternatively called AgentID) in the environment. 
                          Makes sense only if --environment option is specified.
  --agent-lockerpath arg  The locker path of agent.

SSH Options:
  --ssh-host arg        The ssh host to connect to.
  --ssh-port arg        The ssh port to connect to.
  --ssh-user arg        The user to initiate ssh connection.
  --ssh-pass arg        The password to initiate ssh connection.
  --ssh-destdir arg     The destination dir to install the agent to.

Agent Usage:

Usage: agent.exe <options -- all optional>
Program options:
  --service             Install as a Windows service.  Only works on Windows.
  --config arg          An optional configuration file.  Default: agent.xml
  --log arg             An optional file to log to.  Default: standard output
  --loglevel arg        An optional log level.  Can be: none, debug, info,
                        warning, error  Default: warning