Deployment Event Triggers
Deployment event triggers listen to events from status event sources and deployment providers to start releases. Each time a Deployment provider application that existing Live Deployments in the Release server changes its state, the trigger will start a release from the template that is associated with the trigger.
Configure Event-driven Release Orchestration
With Live Deployments, you can listen to deployment events from external tools like Digital.ai Deploy, ArgoCD or FluxCD and trigger creation of a release with live updates in Release.
As you make external deployments part of the release flow, even when they are not orchestrated by Release, you can also embed live deployment events in your release process using triggers.
Create a Deployment Event Trigger
Once you have configured a deployment provider, you can create a deployment event trigger.
- In the sidebar, under the Overview group, click Folders.
- Select or create a new folder, select or create a new Template.
- Add some variables to the template.
- Navigate to the Triggers tab of the folder.
note
You can also create a trigger from inside a template. Select Triggers from the sidebar and click Add trigger. The trigger form will be shown with the template preselected. The remaining steps are the same as below.
- Click Add trigger.
- Select the Deployment event trigger option for the Trigger type field.
- Give it a title and a description, and ensure it is enabled.
- Select the Event source this trigger should react to. The list will include all the event sources defined in this folder and its parents.
- Select Application title and Environment title that are suggested for selected Event source.
- Add an Application version, or use empty or
*
to match any version. - Add a list of Deployment statuses to match when activating trigger (for example, DONE on Digital.ai Deploy or any valid status of Deployment provider service).
- In the Release title, you can either enter a title manually or click
to select a property from the event body (or a folder/global variable) to populate the title.
- For deployment provider events, properties like
applicationTitle
,environmentTitle
, anddeploymentState
can be used. See Deployment Provider Event Source Properties. - In Tags, either enter a list of new tags separated by pressing Enter, or click
to select a source to populate tags.
- If there are template variables, the fields will already be populated with the default values. You can either overwrite this or use the
icon to select a source to populate the variables.
- Click Save.
To trigger a release when a deployment succeeds, select a deployment provider event source and set up filters to capture the deploymentState
as SUCCESS
.
Deployment Provider Event Source Properties
Here's the list of deployment provider event source properties that you can use to build your filter rules:
Property | Description |
---|---|
operation | Deployment operation such as create, remove or update deployment |
configId | Status Webhook Event Source Configuration ID associated with the deployment |
applicationCuid | Application correlation ID |
applicationTitle | Application title |
applicationSource | Application source associated with the event |
environmentCuid | Environment correlation ID |
environmentTitle | Environment title |
deploymentTarget | Deployment target associated with the event |
deploymentState | Snapshot state of deployment |
Mapping JSON Properties to Template Variables
It is possible to bind only event body data to template variables and URL parameters. Headers can only be used in filtering.
Webhook JSON body values can be obtained from the event
variable using JSONPath syntax. You can either access the variable using XLR variable syntax (${event.sender.login
}), or directly map JSON value to XLR variable (XLR will do type conversions to the best of its ability).
If the referenced field is not present, an exception will be thrown and the trigger will not execute.
Example of mapping event JSON to Template variables
Deployment Event Permissions
Deployment event triggers have the same permissions as other trigger types. Users should have "Manage triggers" permissions to create or edit deployment event triggers.
Ensure permissions are correctly set for the deployment provider being used. This includes access to the environments, applications, and deployment states relevant to the events being triggered.