from keystoneclient import discover from keystoneclient import session from keystoneclient.auth.identity import v2 as v2_auth from keystoneclient.auth.identity import v3 as v3_auth from keystoneclient.exceptions import DiscoveryFailure import six.moves.urllib.parse as urlparse from oslo_utils import encodeutils from oslo_utils import importutils from oslo_utils import strutils osprofiler_profiler = importutils.try_import("osprofiler.profiler") from cinderclient import _i18n # Enable i18n lazy translation _i18n.enable_lazy() DEFAULT_MAJOR_OS_VOLUME_API_VERSION = "2" DEFAULT_CINDER_ENDPOINT_TYPE = 'publicURL' V1_SHELL = 'cinderclient.v1.shell' V2_SHELL = 'cinderclient.v2.shell' V3_SHELL = 'cinderclient.v3.shell' logging.basicConfig() logger = logging.getLogger(__name__) class CinderClientArgumentParser(argparse.ArgumentParser): def __init__(self, *args, **kwargs): super(CinderClientArgumentParser, self).__init__(*args, **kwargs)
from oslo_utils import importutils osprofiler_profiler = importutils.try_import("osprofiler.profiler") # noqa import requests import six import six.moves.urllib.parse as urlparse import cinderclient from cinderclient import _i18n from cinderclient._i18n import _ from cinderclient import api_versions from cinderclient import client from cinderclient import exceptions as exc from cinderclient import utils # Enable i18n lazy translation _i18n.enable_lazy() DEFAULT_MAJOR_OS_VOLUME_API_VERSION = "3" DEFAULT_CINDER_ENDPOINT_TYPE = 'publicURL' V1_SHELL = 'cinderclient.v1.shell' V2_SHELL = 'cinderclient.v2.shell' V3_SHELL = 'cinderclient.v3.shell' HINT_HELP_MSG = (" [hint: use '--os-volume-api-version' flag to show help " "message for proper version]") logging.basicConfig() logger = logging.getLogger(__name__) class CinderClientArgumentParser(argparse.ArgumentParser): def __init__(self, *args, **kwargs):