For this demonstration we’ll use a system command as a stand-in for the security software required by Don’s company. The command will save the filename and time to a text file. If this succeeds, we’ll consider the file “safe.” In the real world, this command could be replaced by any security software your company needs to run.
Create a Job to screen outgoing reports
Log into Gateway Administrator as Don using the password you specified when you created this account.
Go to
> .For Reports.
enterFor
, leave selected for initial testing. You can use the feature to test disabled Jobs. After you are satisfied that the Job runs as expected, you can select to run the Job at the specified scan interval.Under c:\reports directory. Click Browse and select the reports directory. This sets up the directory to be scanned. Any new or updated files in this directory will trigger the Job actions you configure.
, select the SFTP server on which you created the accessibleFor this test, we want to scan and move only PDF documents. To do this, next to .*\.pdf in the text box. This regular expression filters for all files with a pdf file extension. Check to be sure you’ve entered it correctly, including both periods.
, click . Select and enterClick
to return to the page.Under
, from the drop-down list, select . In the Execute Command dialog box, for Server, select your Reports Server. For Command, enter the following:cmd /c echo $FILENAME$ $DATE$ $TIME$ >> c:\reports\safefiles.txt
This command will be our stand-in for a security test. For the purposes of this demo, if files can be successfully written to safefiles.txt, the test passes.
NOTE:On Windows servers, you need to precede DOS commands with cmd /c. The /c switch specifies that cmd should exit after the specified command is carried out.
Click
to return to the page.Under
, click to configure email notifications. In the Success Action dialog box, click and enter the email address you used for Don’s account. Use the button to add the $JOB_NAME$ token. It will be replaced with the Job name in the email message:Click
to return to the page.Create a
in the same way.Click
.Test your Job
On the Reports server, copy one or more *.pdf files to c:\reports.
In Gateway Administrator, go to the Reports Job and click .
page, select theClick
to test the action. You’ll see a Running Job message. This tells you the Job has been initiated. You can close this message at any time; it has no effect on execution of Job actions.If the Job works, you should see a new file called safefiles.txt in the reports folder on your Reports server and you should receive a success notification in the email you specified.
If your Job did not work as expected, review these instructions, or refer to the testing notes and troubleshooting help in the Administrator’s Guide.
NOTE:If you make modifications to your Job, ensure that there are new or updated files in the scanned directory before each test.
Make a copy of the working Job
After you get your Job working, you can make a copy of it and use the copy to experiment. When you’re ready to continue with the procedures in this guide, you can return to the original Job.
In Gateway Administrator, go to the Reports Job and click .
page, select theConfirm that you want to make the copy. This creates a new Job called Reports_copy1.