5 =head1 NAME $RCSfile: index.cgi,v $
7 Clearadm: Portal to your Clearcase Infrastructure
15 Andrew DeFaria <Andrew@ClearSCM.com>
23 Mon Oct 25 11:10:47 PDT 2008
27 $Date: 2011/02/14 14:50:48 $
33 Clearadm is a web based portal into your Clearcase infrastucture. It seeks to
34 provide your CM staff with an easy to use, yet informative interface to locate,
35 report on and monitor various aspects of the Clearcase infrastructure.
45 use CGI qw (:standard *table start_Tr end_Tr);
46 use CGI::Carp 'fatalsToBrowser';
48 use lib "$FindBin::Bin/lib", "$FindBin::Bin/../lib";
53 #use Clearcase::Views;
57 my $clearadm = Clearadm->new;
61 'usage' => sub { Usage },
62 'verbose' => sub { set_verbose },
63 'debug' => sub { set_debug },
64 ) or Usage "Invalid parameter";
67 verbose "$ClearadmWeb::APPNAME V$ClearadmWeb::VERSION";
73 Clearadm is a web based portal into your infrastructure. It seeks to provide
74 your system administrative staff with an easy to use, yet informative interface
75 to locate, report on and monitor various aspects of your infrastructure.
78 Additionally, Clearacdm is aware of Clearcase servers as well as Clearcase
79 objects such as views, vobs, etc. When systems are added to Clearadm that house
80 or server Clearcase objects, additional information is collected about those
84 display h1 {class => 'center'}, 'Systems Snapshot';
86 display start_table {cellspacing => 1};
93 my @systems = $clearadm->FindSystem;
95 $perRow = @systems if @systems < $perRow;
100 if ($i++ % $perRow == 0) {
105 my %load = $clearadm->GetLatestLoadavg ($system{name});
110 if $system{active} eq 'false';
113 href => "systemdetails.cgi?system=$system{name}"
114 }, ucfirst $system{name};
116 if ($system{notification}) {
117 $data .= ' ' . a {
118 href => "alertlog.cgi?system=$system{name}"}, img {
122 title => 'This system has alerts',
128 "plot.cgi?type=loadavg&system=$system{name}&scaling=Hour&points=24"
130 src => "plotloadavg.cgi?system=$system{name}&tiny=1",
135 if $system{active} eq 'false';
137 display td {class => 'dataCentered'}, "$data ",
138 font {class => 'dim' }, "<br>Up: $load{uptime}";
141 while ($i % $perRow != 0) {
143 display td {class => 'data'}, ' ';
154 =head1 CONFIGURATION AND ENVIRONMENT
156 DEBUG: If set then $debug is set to this level.
158 VERBOSE: If set then $verbose is set to this level.
160 TRACE: If set then $trace is set to this level.
168 L<CGI::Carp|CGI::Carp>
172 L<Getopt::Long|Getopt::Long>
174 =head2 ClearSCM Perl Modules
188 <a href="http://clearscm.com/php/scm_man.php?file=clearadm/lib/Clearadm.pm">Clearadm</a><br>
189 <a href="http://clearscm.com/php/scm_man.php?file=clearadm/lib/ClearadmWeb.pm">ClearadmWeb</a><br>
190 <a href="http://clearscm.com/php/scm_man.php?file=lib/Display.pm">Display</a><br>
191 <a href="http://clearscm.com/php/scm_man.php?file=lib/Utils.pm">Utils</a><br>
196 =head1 BUGS AND LIMITATIONS
198 There are no known bugs in this script
200 Please report problems to Andrew DeFaria <Andrew@ClearSCM.com>.
202 =head1 LICENSE AND COPYRIGHT
204 Copyright (c) 2010, ClearSCM, Inc. All rights reserved.