'Clone an existing image volume.'

@locked_image_id_operation
def clone_image(self, context, volume, image_location, image_meta, image_service):

    public = False
    if (not self.configuration.sf_allow_template_caching):
        return (None, False)
    visibility = image_meta.get('visibility', None)
    if (visibility and (visibility == 'public')):
        public = True
    elif image_meta.get('is_public', False):
        public = True
    elif (image_meta['owner'] == volume['project_id']):
        public = True
    if (not public):
        LOG.warning('Requested    image    is    not    accessible    by    current    Tenant.')
        return (None, False)
    try:
        self._verify_image_volume(context, image_meta, image_service)
    except exception.SolidFireAPIException:
        return (None, False)
    (data, sfaccount, model) = self._do_clone_volume(image_meta['id'], volume)
    return (model, True)
