We are currently using a template in Digital.ai Release to trigger a deployment in Digital.ai Deploy, and then update a Jira task with a comment based on whether the deployment was successful or not. Our end users do not log into Release or Deploy, they instead use the updates that Release posts into Jira and therefore if a Deployment fails we need to advise them why it failed.
We want to be able to capture the Deploy failure messages / deployment task log where a deployment fails and then use this within a subsequent "Jira: Update Issue" task. To attempt to achieve this currently we are using a failure handler script on the Deployment task to capture the Release task id, then we have another Jython script task that looks at the comments on this task, writes the penultimate comment to a variable (as the last comment is usually a comment stating the Release task has been skipped by the failure handler), and then a separate Jira task that writes that variable to a Jira ticket. This is only working on some failures as it depends which comment is outputting the actual Deploy error. We are unable to append all step log comments to a variable as these are typically too long.
Therefore we would like to capture the deployment step logs / error messages and write these to a variable or log file to be able to use in subsequent tasks.