Comment 5 for bug 1713871

Revision history for this message
Daniel Manrique (roadmr) wrote :

This is a horrible workaround, please don't use it.

If your environment allows (mine does, mojo deploying to a same-machine Juju controller on a VM inside a closed network, so it's super isolated), you can disable SSL cert checking and move ahead:

sudo vim /usr/lib/python3/dist-packages/jujuclient/connector
.py

look for def connect_socket(... and set sslopt['cert_reqs'] to ssl.CERT_NONE. The method should look like this after the surgery:

    def connect_socket(cls, endpoint, cert_path=None):
        """Return a websocket connection to an endpoint."""

        sslopt = cls.get_ssl_config(cert_path)
        sslopt['cert_reqs'] = ssl.CERT_NONE # I added this line
        return websocket.create_connection(
            endpoint, origin=endpoint, sslopt=sslopt)

Mojo should work after this.

To repeat, this is horrid because it entirely disables cert verification :( so please don't do it.