'Creates a new Rancher Container driver.
:param    key: API key or username to used (required)
:type     key: ``str``
:param    secret: Secret password to be used (required)
:type     secret: ``str``
:param    secure: Whether to use HTTPS or HTTP.
:type     secure: ``bool``
:param    host: Override hostname used for connections. This can also
be a full URL string, including scheme, port, and base path.
:type     host: ``str``
:param    port: Override port used for connections.
:type     port: ``int``
:return: A newly initialized driver instance.'

def __init__(self, key, secret, secure=True, host='localhost', port=443):

    if (('://' not in host) and (not host.startswith('//'))):
        host = ('//' + host)
    parsed = urlparse.urlparse(host)
    super(RancherContainerDriver, self).__init__(key=key, secret=secret, secure=(False if (parsed.scheme == 'http') else secure), host=parsed.hostname, port=(parsed.port if parsed.port else port))
    self.baseuri = (parsed.path if parsed.path else ('/v%s' % self.version))
