use ClusterSSH::Host; my $host = ClusterSSH::Host->new({ hostname => 'hostname', }); my $host = ClusterSSH::Host->parse_host_string('username@hostname:1234');
Object representing a host. Include details to contact the host such as hostname/ipaddress, username and port.
Create a new host object. 'hostname' is a required arg, 'username' and 'port' are optional. Raises exception if an error occurs.
Return specific details about the host
Set specific details about the host after its been created.
If the server name provided is not an IP address (either IPv4 or IPv6) attempt to resolve it and retun the discovered names.
Alias to get_hostname, for use when get_realname might return something different
get_realname
Given a host string, returns a host object. Parses hosts such as
Check the objects hostname to see whether or not it may be configured within the users $HOME/.ssh/config configuration file
Method to ease reading in ssh configuration files. Used for grabbing hostnames for validation when used in clusters
and so on. Cope with IPv4 and IPv6 addresses - raises a warning if the IPv6 address is ambiguous (i.e. in the last example, is the 4567 part of the IPv6 address or a port definition?) and assumes it is part of address. Use brackets to avoid seeing warning.
To install App::ClusterSSH, copy and paste the appropriate command in to your terminal.
cpanm
cpanm App::ClusterSSH
CPAN shell
perl -MCPAN -e shell install App::ClusterSSH
For more information on module installation, please visit the detailed CPAN module installation guide.