Utility - exportJSONComplianceJobRunDetails


Utility - exportJSONComplianceJobRunDetails

Description :

This command exports the JSON file which contains details about the job run.

Return type : java.lang.Void

Command Input :

Variable Name

Variable Type

Description

runId

Integer

ID of the Compliance Job run whose results you want to export.

exportDirectory

String

Name of the directory that holds the export.

This field accepts a valid NSH path in the following format: //serverName/<path to dir>/fileName. If you provide a local path, /<path to dir>/fileName, the local path is created on the application server and the export is stored in that path.

Example

The following example shows how to export the selected job run result of a Compliance Job.

Script

JOB_GROUP="/sampleJobGroup"

JOB_NAME="sampleJob"

JOB_DB_KEY=`blcli ComplianceJob getDBKeyByGroupAndName $JOB_GROUP $JOB_NAME`

JOB_RUN_KEY=`blcli JobRun findAllRunKeysByJobKey $JOB_DB_KEY`

JOB_RUN_ID=`blcli JobRun jobRunKeyToJobRunId $JOB_RUN_KEY`

JSON_COMPLIANCE_JOBRUN_EXPORT=`blcli Utility exportJSONComplianceJobRunDetails $JOB_RUN_ID "//hostname/c/reports"`

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

TrueSight Server Automation Command Line Interface 23.2