NAME
DynGig::CLI::OpsDB - CLI for a simple operations database
EXAMPLE
use DynGig::CLI::OpsDB;
DynGig::CLI::OpsDB->main
(
master => 'hostname',
database => '/database/directory/path',
);
SYNOPSIS
$exe --help
$exe --range range [--count | --delete] [--format format]
$exe --Regex range [--count | --delete] [--format format]
[echo YAML |] $exe YAML [--count | --delete] [--format format]
[echo YAML |] $exe YAML --update
e.g.
To read help menu
$exe --help
To display records of host001 to host004, in CSV form by name,colo,rack
$exe -r host001~4 -f '"%s,%s,%s",name,colo,rack'
To display records that match /host00?/, in raw YAML form
$exe -R 'host00?'
To display the records of hosts in area A, cab 6, in raw YAML form
$exe '{area: A, rack: 6}'
To count the above records
$exe '{area: A, rack: 6}' -c
To delete the above records
$exe '{area: A, rack: 6}' -d
To add/update host008,
$exe 'host008: {area: A, rack: 6, ..}' -u
NOTE
See DynGig::CLI