Clustericious::Config::Helpers - Helpers for clustericious config files.
version 1.25
--- % extend_config 'SomeOtherConfig';
This module provides the functions available in all configuration files using Clustericious::Config.
% extends_config $config_name, %arguments
Extend the config using another config file.
<%= get_password %>
Prompt for a password. This will prompt the user the first time it is encountered for a password.
<%= home %> <%= home $user %>
Return the given users' home directory, or if no user is specified return the calling user's home directory.
<%= file @list %>
The file shortcut from Path::Class, if it is installed.
file
<%= dir @list %>
The dir shortcut from Path::Class, if it is installed.
dir
<%= hostname %>
The system hostname (uses Sys::Hostname)
<%= hostname_full %>
The system hostname in full, including the domain, if it can be determined (uses Sys::Hostname).
<%= json $ref %>
Encode the given hash or list reference.
<%= yaml $ref %>
<%= address %> <%= address $interface %>
Returns a list of IP addresses. Requires Sys::HostAddr to be installed. $interfaces, if specified may be either a string or regular expression. For example you can do address qr{^en[0-9]+$} on Linux to get only ethernet interfaces.
$interfaces
address qr{^en[0-9]+$}
By default does not return loop back interfaces.
Only returns IPv4 addresses.
<%= public_address %>
Returns the public IPv4 address. May not be an address on your host, if you are behind a firewall. Requires Sys::HostAddr to be installed.
<%= join ' ', interfaces %>
Returns a list of network interfaces. Requires Sys::HostAddr to be installed.
Clustericious::Config, Clustericious
Original author: Brian Duggan
Current maintainer: Graham Ollis <plicease@cpan.org>
Contributors:
Curt Tilmes
This software is copyright (c) 2013 by NASA GSFC.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Clustericious, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Clustericious
CPAN shell
perl -MCPAN -e shell install Clustericious
For more information on module installation, please visit the detailed CPAN module installation guide.