Supported Types

Available puppet methods and attributes

opsview_attribute

Parameter/PropertyDescriptionFormat
nameName of the attributeString
reload_opsviewWhether to perform a reloadTrue or false
attributeName of the attributeString
valueAttribute valueString
label1Attribute 1 labelString
label2Attribute 2 labelString
label3Attribute 3 labelString
label4Attribute 4 labelString
secured1arg1 is an encrypted value0 or 1
secured2arg2 is an encrypted value0 or 1
secured3arg3 is an encrypted value0 or 1
secured4arg4 is an encrypted value0 or 1
arg1Value for arg1String
arg2Value for arg2String
arg3Value for arg3String
arg4Value for arg4String
encrypted_arg1Encrypted value for arg1String
encrypted_arg2Encrypted value for arg2String
encrypted_arg3Encrypted value for arg3String
encrypted_arg4Encrypted value for arg4String

Example

opsview_attribute{"NORMALATTRIBUTE":
    reload_opsview => false,
    ensure => present,
    value => 'This is the value',
    arg1 => 'arg1',
    arg2 => 'arg2',
    arg3 => 'arg3',
    arg4 => 'arg4'
}
opsview_attribute {"BLANKENCRYPTEDATTRIBUTE":
    reload_opsview => false,
    ensure => present,
    value => 'This is the value',
    secured1 => 1,
    secured2 => 1,
    secured3 => 1,
    secured4 => 1
}
opsview_attribute {"ENCRYPTEDATTRIBUTE":
    reload_opsview => false,
    ensure => present,
    value => 'This is the value',
    label1 => 'label1',
    label2 => 'label2',
    label3 => 'label3',
    label4 => 'label4',
    encrypted_arg1 => 'b8a98ef9a82aa1012a8cbec292224ee4413c4a1b1343afe4f5adcb51191bd77c',
    encrypted_arg2 => 'b8a98ef9a82aa1012a8cbec292224ee4413c4a1b1343afe4f5adcb51191bd77c',
    encrypted_arg3 => 'b8a98ef9a82aa1012a8cbec292224ee4413c4a1b1343afe4f5adcb51191bd77c',
    encrypted_arg4 => 'b8a98ef9a82aa1012a8cbec292224ee4413c4a1b1343afe4f5adcb51191bd77c'
}

opsview_bsmcomponent

Parameter/PropertyDescriptionFormat
nameName of the business componentString
reload_opsviewWhether to perform a reloadTrue or false
hostsList of hosts that are included in the componentArray of strings
hosttemplateHost template to useString
required_onlineHow many hosts need to be onlineInteger
has_icon
Integer

Example

opsview_bsmcomponent {"networkstack":
    ensure => present,
    hosts => [
        "ciscoswitch1", 
        "ciscoswitch2" 
    ],
    hosttemplate => 'Network - Base',
    required_online => 1
}

opsview_bsmservice

Parameter/PropertyDescriptionFormat
nameName of the business serviceString
reload_opsviewWhether to perform a reloadTrue or false
componentsComponents that are part of the BSM serviceArray of strings

Example

opsview_bsmservice {"companywebsite":
    reload_opsview => 'false',
    ensure => present,
    components => [
        "bsmcomponenttest1", 
        "bsmcomponenttest2"
    ]
}

opsview_contact

Parameter/PropertyDescriptionFormat
nameName of the contactString
reload_opsviewWhether to perform a reloadTrue or false
fullnameFull name of userString
descriptionDescription of contactString
roleRole that the user is inString
encrypted_passwordUser’s passwordString
languageUser’s languageString
variablesUser variablesHash - e.g. {'EMAIL' => '[email protected]'}

opsview_hostgroup

Parameter/PropertyDescriptionFormat
nameName of the host groupString
reload_opsviewWhether to perform a reloadTrue or false
hostgroupName of the hostgroupString
parentParent of hostgroupString

Example

opsview_hostgroup {"myhostgroupname":
    ensure => present,
    reload_opsview => false,
    parent => "linux"
}

opsview_hosttemplate

Parameter/PropertyDescriptionFormat
nameName of the host templateString
reload_opsviewWhether to perform a reloadTrue or false
hosttemplateName of the host templateString
descriptionDescription of templateString
servicechecksList of service checks to includeArray of strings
managementurlsList of management URLsArray of hashes. Available keys are name and url

Example

opsview_hosttemplate {'mytemplate':
    managementurls => [ 
        { 'name' => 'wiki', 'url' =>'https://www.google.com/ ' } 
    ],
    description => 'networking template',
    servicechecks =>  [
        'ping check',
        'uptime restart' 
    ],
}

opsview_keyword

Parameter/PropertyDescriptionFormat
nameName of the keywordString
reload_opsviewWhether to perform a reloadTrue or false
keywordName of the keywordString
descriptionDescription of keywordString
viewportViewport is enabled0 or 1
all_hostsKeyword applied to all hosts0 or 1
all_servicechecksKeyword applied to all service checks0 or 1
styleViewport display styleerrors_and_host_cells, group_by_host, group_by_service, host_summary, performance
hostsList of hosts to tagArray of strings
servicechecksList of service checks to tagArray of strings
rolesList of roles that can view keywordArray of strings

opsview_monitored

Parameter/PropertyDescriptionFormat
nameName of the hostString
reload_opsviewWhether to perform a reloadTrue or false
ipIP address of hostString
hostgroupHostgroup to put host inString
hosttemplatesTemplates assigned to hostArray of strings
servicechecksService checks assigned to hostArray of strings
keywordsKeywords assigned to hostArray of strings
monitored_byName of the monitoring server for the hostString
parentsParents of the hostArray of strings
enable_snmpWhether snmp is enabled0 or 1
notification_intervalHow long between host notificationsInteger
encrypted_snmp_communityCommunity string for hostString
snmp_versionSNMP versionString
snmp_portSNMP port numberInteger
snmpv3_usernameUsername for V3String
encrypted_snmpv3_authpasswordAuth password for V3String
snmpv3_authprotocolAuth protocol for V3md5 or sha
encrypted_snmpv3_privpasswordPriv password for V3String
snmpv3_privprotocolPriv protocoldes, aes, aes128
snmp_max_msg_sizeSNMP Message sizedefault, 1Kio, 2Kio, 4Kio, 8Kio, 16Kio, 4Kio, 64Kio
tidy_ifdescr_levelLevel for tidying ifdescr stringoff, level1, level2, level3
snmp_extended_throughput_dataGather extended data
icon_nameName of iconString
check_commandHost check commandString
hostattributesHost attributes for the hostArray of hashes. Available keys are name, value, arg1, arg2, arg3, arg4, encrypted_arg1, encrypted_arg2, encrypted_arg3, encrypted_arg4
snmpinterfacesList of available SNMP interfacesArray of hashes. Available keys are interfacename, active, discards_critical, errors_critical, throughput_critical, throughput_warning

Example

opsview_monitored {"snmpdevice":
    ensure => present,
    reload_opsview => false,
    ip => 'localhost',
    hosttemplates => ['SNMP - MIB-II'],
    hostgroup => 'networking',
    enable_snmp => 1,
    snmp_version => "2c",
    notification_interval => 60,
    snmpinterfaces => [
        {"interfacename"=>"", "active"=>"0", "discards_critical"=>"15", "errors_critical"=>"10", "throughput_critical"=>"0:50%", "throughput_warning"=>"0:25%"},
         {"interfacename"=>"Ethernet0/1", "active"=>"1", "discards_critical"=>"", "discards_warning"=>"", "errors_critical"=>"", "throughput_critical"=>"", "throughput_warning"=>"0:75%"},
        {"interfacename"=>"Null0", "active"=>"0", "discards_critical"=>"", "discards_warning"=>"", "errors_critical"=>"", "throughput_critical"=>"", "throughput_warning"=>""},
    ]
}
opsview_monitored {"hostwithencryptedargs":
    ensure => present,
    reload_opsview => false,
    ip => "localhost",
    hostgroup => 'puppet',
    hostattributes => [
        { name => "MYSQLCREDENTIALS", value => "/", arg1 => 'dbuser', encrypted_arg2 => 'c5aeaf4f0546ca70d6a89b9056eade8228162c8abcbc4e021c46a3a4309d1a7c'},
        { name => "SOMEENCRYPTEDATTRIBUTE", value => "placeholder", encrypted_arg1 => 'c5aeaf4f0546ca70d6a89b9056eade8228162c8abcbc4e021c46a3a4309d1a7c'},
    ]
}

opsview_monitoringserver

Parameter/PropertyDescriptionFormat
nameName of the monitoring serverString
reload_opsviewWhether to perform a reloadTrue or false
activatedWhether the monitoring server is activated0 or 1
nodesList of slave nodesArray of strings
passiveWhether passive is on0 or 1
ssh_tunnelType of tunnelforward, reverse, 0, 1

opsview_notificationmethod

Parameter/PropertyDescriptionFormat
nameName of the notification methodString
reload_opsviewWhether to perform a reloadTrue or false
masterEnabled on master
activeWhether or not active
commandCommand to runString
contact_variablesComma separated list of valuesString

opsview_role

Parameter/PropertyDescriptionFormat
nameName of the roleString
reload_opsviewWhether to perform a reloadTrue or false
roleName of the roleString
descriptionDescription of roleString
all_hostgroupsAccess to all hostgroupstrue or false
all_servicegroupsAccess to all service groupstrue or false
all_keywordsAccess to all keywordstrue or false
all_bsm_componentsAccess to all BSM componentstrue or false
all_bsm_editCan edit all BSM servicestrue or false
all_bsm_viewCan view all BSM servicestrue or false
all_monitoringserversCan configure on all monitoring serverstrue or false
access_hostgroupsHost groups role can accessArray of strings
access_servicegroupsService groups role can accessArray of strings
access_keywordsKeywords role can accessArray of strings
accessesList of access propertiesArray of strings
business_servicesAuthorized services for roleArray of hashes. Available keys are name and edit
hostgroupsList of hostgroups role can configureArray of strings
monitoringserversList of monitoringservers role can configureArray of strings
tenancyTenancy role is a member ofString

Example

opsview_role {"myrole":
    ensure => present,
    reload_opsview => false,
    all_bsm_edit => true,
    all_bsm_view => true,
    all_bsm_components => true,
    all_monitoringservers => true,
    accesses => [
        'BSM',
        'CONFIGUREBSM',
        'CONFIGUREBSMCOMPONENT'
    ]      
}
opsview_role {"myrole2":
    ensure => present,
    reload_opsview => false,
    accesses => [
        'BSM',
        'CONFIGUREBSM',
        'CONFIGUREBSMCOMPONENT'
    ],
    business_services => [ 
        { name => 'company website', edit => 1 }, {name => 'sales team'} 
    ],
    monitoringservers => ['Master Monitoring Server']   
}

opsview_servicecheck

Parameter/PropertyDescriptionFormat
nameName of the hostString
reload_opsviewWhether to perform a reloadTrue or false
checktypeType of service checkActive Plugin, SNMP trap, Passive, SNMP Polling
descriptionDescription of service checkString
servicegroupService group to put check intoString
dependenciesList of dependent servicesArray of strings
keywordsList of keywordsArray of string
calculate_rateSNMP polling rate fieldno, per_second, per_minute, per_hour
critical_comparisonSNMP critical comparisonnumber, ==, <, >, separator, string, eq, ne, regex
warning_comparisonSNMP warning comparisonnumeric,==,<,>
labelSNMP OID labelString
oidSNMP OIDString
critical_valueSNMP Polling thresholdString
warning_valueSNMP Polling thresholdString
notification_intervalInterval to notifyInteger
notification_optionsNotification optionsString - i.e. ‘w,u,o’
notification_periodPeriod to notifyString
attributeAttribute to useString
event_handlerEvent handler to runString
flap_detectionFlap detection0 or 1
markdown_filterMarkdown filter0 or 1
sensitive_argumentsSensitive arguments0 or 1
alert_every_failureAlert every failure0, 1, 2, enable, disable, enable with re-notification interval
record_output_changesRecord output changes0 or 1
actionPassive check actionset_stale, renotify, resend notifications, submit results
statePassive state to submitWARNING, CRITICAL, OK, UNKNOWN, 0, 1, 2, 3
timeoutPassive timeouttime syntax - i.e. 5, 10s, 20m, 1h, 2d, 18h 20m
alert_from_failureNotification counter to alert onInteger
cascaded_fromPassive cascaded serviceString
check_freshnessWhether to check freshness0 or 1
textText for passive messageString
snmptraprulesSNMP Trap rule definitionArray of hashes. Available keys are action, alert_level, rule, name
check_periodCheck period to runString
check_intervalCheck interval for serviceInteger
check_attemptsCheck attempt for serviceInteger
retry_check_intervalRetry check interval for serviceInteger
pluginWhich plugin to useString
argsArguments to pluginString
invertresultsInvert results0 or 1

Example

opsview_servicecheck {"snmptrap":
    ensure => present,
    servicegroup => 'snmp',
    reload_opsview => false,
    checktype => 'SNMP trap',
    snmptraprules => [
        {'action' => 'Send Alert', 'alert_level' => 'WARNING', 'message' => 'This is the message ${DUMP}', 'name' => 'Rule 1', 'rule' => '"${TRAPNAME}" eq "trap"'},
        {'action' => 'Stop Processing', 'alert_level' => 'CRITICAL', 'message' => 'This is the message ${DUMP}', 'name' => 'Rule 2', 'rule' => '"${TRAPNAME}" eq "trap"'},
        {'action' => 'Send Alert', 'alert_level' => 'WARNING', 'message' => 'This is the message ${DUMP}', 'name' => 'Rule 3', 'rule' => '"${TRAPNAME}" eq "trap"'}
    ]
}
opsview_servicecheck {"snmppolling":
    ensure => present,
    servicegroup => 'snmp',
    reload_opsview => false,
    checktype => 'SNMP Polling',
    calculate_rate => 'per_second',
    oid => 'IF-MIB::ifInNUcastPkts.1',
    label => 'OidLabel',
    warning_value => 3,
    warning_comparison => '==',
    critical_value => 5,
    critical_comparison => '>'
}
opsview_servicecheck {"passivecheck":
    ensure => present,
    servicegroup => 'externalhosts',
    reload_opsview => false,
    checktype => 'Passive',
    check_freshness => 1,
    cascaded_from => 'DHCP',
    action => 'Submit Result',
    timeout => '30h 10m',
    text => "This is the stale text"
}
opsview_servicecheck {"activetest3":
    ensure => present,
    description => 'Managed by puppet',
    servicegroup => 'puppet-testing',
    reload_opsview => false,
    interval_mode => clever,
    checktype => 'Active Plugin',
    plugin => 'check_tcp',
    args => '-H localhost -p 443',
    check_interval => '30'
}

opsview_servicegroup

Parameter/PropertyDescriptionFormat
nameName of the service groupString
reload_opsviewWhether to perform a reloadTrue or false
servicegroupName of the service groupString

Example

opsview_servicegroup {"nameofgroup":
    ensure => present
}

opsview_tenancy

Parameter/PropertyDescriptionFormat
nameName of the tenancyString
reload_opsviewWhether to perform a reloadTrue or false
primary_rolePrimary role to useString
priority

|
|
| description | Description of tenancy | String |

Example

opsview_tenancy {"mytenancy":
    ensure => present,
    description => 'Managed by puppet',
    reload_opsview => false,
    primary_role => 'myrole',      
}
opsview_role {"tenancyrole":
    ensure => present,
    reload_opsview => false,
    tenancy => 'mytenancy'
}