Reboot a node

    CLI Examples:

    .. code-block:: bash

        salt-cloud -a reboot myinstance

def reboot(name, call=None):
    '''
    Reboot a node

    CLI Examples:

    .. code-block:: bash

        salt-cloud -a reboot myinstance
    '''
    if call != 'action':
        raise SaltCloudSystemExit(
            'The stop action must be called with -a or --action.'
        )

    log.info('Rebooting node %s', name)

    instance_id = _get_node(name)['InstanceId']

    params = {'Action': 'RebootInstance',
              'InstanceId': instance_id}
    result = query(params)

    return result