Skip to content

Commit

Permalink
fix(zabbix agent): workaround module.run syntax change
Browse files Browse the repository at this point in the history
Looks like deprecation of legacy module.run syntax is postponed until Salt v3005
https://docs.saltstack.com/en/latest/ref/states/all/salt.states.module.html#salt.states.module.run

Fix: saltstack-formulas#102
  • Loading branch information
hatifnatt committed Oct 12, 2020
1 parent b93b3b4 commit a68d847
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions zabbix/agent/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ zabbix-agent:
zabbix-agent-restart:
module.wait:
# Deprecation warning about legacy "module.run" syntax still will be thrown if "use_superseded: [module.run]"
# is not enabled in Salt version < 3001. But formula won't break after upgrade to version >= 3001
# is not enabled in Salt version < 3005. But formula won't break after upgrade to version >= 3005
{% if 'module.run' in salt['config.get']('use_superseded', [])
or grains['saltversioninfo'] >= [3001] %}
or grains['saltversioninfo'] >= [3005] %}
- service.restart:
- name: {{ zabbix.agent.service }}
{% else %}
Expand Down

0 comments on commit a68d847

Please sign in to comment.