Symptoms

The following error is shown when running apsconnect init-cluster command while installing APS Connector:

2017-09-21 01:34:28,765 ERROR Certificate did not match expected hostname: 192.168.1.1 Certificate: {'subjectAltName': (('DNS', 'kubernetes'), ('DNS', 'kubernetes.default'), ('DNS', 'kubernetes.default.svc'), ('DNS', 'kubernetes.default.svc.cluster.local'), ('IP Address', '192.168.1.1'), ('IP Address', '192.168.1.1')), 'notBefore': u'Aug 29 12:06:40 2017 GMT', 'serialNumber': u'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx', 'notAfter': 'Aug 28 12:06:40 2022 GMT', 'version': 3L, 'subject': ((('commonName', u'192.168.1.1'),),), 'issuer': ((('commonName', u'xxxxxx-xxxx-xxxx-xxxx-xxxxxxx),),)}

Python 2.7.5 is installed on the host where apsconnect is executed.

Cause

Most likely you are using old version of openssl linked with python.

Resolution

In case of python 2.7.5 it is necessary to run the following commands before installing apsconnect:

yum install python-setuptools
easy_install pip
pip install -U setuptools
pip install -U backports.ssl-match-hostname

After that install apsconnect:

pip install apsconnectcli

Internal content

Link on internal Article