Management of Zabbix usermacros. :codeauthor: Raymond Kuiper <qix@the-wired.net>
Ensures that the mediatype does not exist, eventually deletes the mediatype.
name -- name of the usermacro
hostid -- id's of the hosts to apply the usermacro on, if missing a global usermacro is assumed.
_connection_user -- Optional - zabbix user (can also be set in opts or pillar, see module's docstring)
_connection_password -- Optional - zabbix password (can also be set in opts or pillar, see module's docstring)
_connection_url -- Optional - url of zabbix frontend (can also be set in opts, pillar, see module's docstring)
delete_usermacro:
zabbix_usermacro.absent:
- name: '{$SNMP_COMMUNITY}'
Creates a new usermacro.
name -- name of the usermacro
value -- value of the usermacro
hostid -- id's of the hosts to apply the usermacro on, if missing a global usermacro is assumed.
_connection_user -- Optional - zabbix user (can also be set in opts or pillar, see module's docstring)
_connection_password -- Optional - zabbix password (can also be set in opts or pillar, see module's docstring)
_connection_url -- Optional - url of zabbix frontend (can also be set in opts, pillar, see module's docstring)
override host usermacro:
zabbix_usermacro.present:
- name: '{$SNMP_COMMUNITY}''
- value: 'public'
- hostid: 21