Utility - exportComplianceDetailsServerReport
This command exports the selected servers compliance job run result to a directory and gives you more control over the resulting output than other similar commands. The result is saved in a JSON and HTML format.
Return type : String
Command Input :
ID of the Compliance Job run whose results you want to export.
ID of the server for which the report needs to be generated.
Name of the directory that holds the export.
The following example shows how to export the selected job run result of a Compliance Job. The example also shows how to obtain the server ID and job run ID before running the export command.
SERVER_ID=`blcli Server getServerIdByName "server_name"` JOB_DB_KEY=`blcli ComplianceJob getDBKeyByGroupAndName "/sampleJobGroup" "sampleJob"` JOB_RUN_KEY=`blcli JobRun findAllRunKeysByJobKey $JOB_DB_KEY` JOB_RUN_ID=`blcli JobRun jobRunKeyToJobRunId $JOB_RUN_KEY` COMPLIANCE_JOB_RUN_EXPORT=`blcli Utility exportComplianceDetailsServerReport $JOB_RUN_ID $SERVER_ID "//hostname/c/reports"`