@decorators.which('dig')
def dig(host):
 cmd = 'dig {0}'.format(salt.utils.network.sanitize_host(host))
 return __salt__['cmd.run'](cmd)

@ decorators . which ( 'dig' ) def dig ( host ) : cmd = 'dig {0}' . format ( salt . utils . network . sanitize_host ( host ) ) return __salt__ [ 'cmd.run' ] ( cmd )
performs a dns lookup with dig note: dig must be installed on the windows minion cli example: .