Skip to content

Instantly share code, notes, and snippets.

@spicyjack
Created August 23, 2014 13:32
Show Gist options
  • Save spicyjack/5b34c7ad8ab3c79f5446 to your computer and use it in GitHub Desktop.
Save spicyjack/5b34c7ad8ab3c79f5446 to your computer and use it in GitHub Desktop.
use strict;
use warnings;
use Rex -feature => ["use_server_auth"];
use Rex::Commands::Gather;
use Rex::Group::Lookup::INI;
groups_file "../servers.ini";
desc "Get info about the servers in 'servers.ini'";
### TASK: uptime
task 'uptime', group => 'servers', sub {
my $output = run 'uptime';
say $output;
};
### TASK: system_info
task 'system_info', group => 'servers', sub {
say dump_system_information();
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment