The Perl and Raku Conference 2025: Greenville, South Carolina - June 27-29 Learn more

#!perl
use strict;
use GTop::Server ();
my $gtops = GTop::Server->new;
my $config = shift || "server.conf";
if (-e $config) {
print "reading server config from $config..\n";
$gtops->read_config($config);
}
else {
print "$config not found, falling back to default config..\n";
#same as server.conf
$gtops->allow("127.0.0.1");
$gtops->debug(1);
$gtops->no_fork(1);
$gtops->no_daemon(1);
}
$gtops->start;