

def send_msg(name, recipient, subject, sender, profile, use_ssl='True'):
    "\n    Send a message via SMTP\n\n    .. code-block:: yaml\n\n        server-warning-message:\n          smtp.send_msg:\n            - name: 'This is a server warning message'\n            - profile: my-smtp-account\n            - subject: 'Message from Salt'\n            - recipient: admin@example.com\n            - sender: admin@example.com\n            - use_ssl: True\n\n    name\n        The message to send via SMTP\n    "
    ret = {
        'name': name,
        'changes': {
            
        },
        'result': None,
        'comment': '',
    }
    if __opts__['test']:
        ret['comment'] = 'Need to send message to {0}: {1}'.format(recipient, name)
        return ret
    command = __salt__['smtp.send_msg'](message=name, recipient=recipient, profile=profile, subject=subject, sender=sender, use_ssl=use_ssl)
    if command:
        ret['result'] = True
        ret['comment'] = 'Sent message to {0}: {1}'.format(recipient, name)
    else:
        ret['result'] = False
        ret['comment'] = 'Unable to send message to {0}: {1}'.format(recipient, name)
    return ret

dataset/ETHPy150Open saltstack/salt/salt/states/smtp.py send_msg/original