You can define a UNIX job to run a Perl script.
To run a Perl script on UNIX
oscomponent.validshell=/usr/bin/sh,/bin/csh,/bin/ksh,/usr/local/bin/perl,/usr/local/bin/bash
Note: If the oscomponent.checkvalidshell parameter is set to false, you do not need to perform the first step.
SCRIPTNAME /bin/cmd1.pl
Perl Script cmd1.pl
#!/usr/local/bin/perl
print " $0 @ARGV\n";
while (( $var, $value) = each %ENV) {
print "$var = $value\n";
}
$live=$ENV{pick};
print " user variable pick = $live\n";
SHELL /usr/local/bin/perl
Example: Run a Perl Script
This example runs the Perl script named cmd1.pl. The path to the Perl interpreter, /usr/local/bin/perl, is specified in the SHELL statement.
AGENT SUN30RD SCRIPTNAME /bin/cmd1.pl SHELL /usr/local/bin/perl ARGS Hello world USER guest
|
Copyright © 2013 CA Technologies.
All rights reserved.
|
|