python操作minio,总是会报错,MaxRetryError错误。
File "/usr/local/lib/python2.7/dist-packages/urllib3/util/retry.py", line 446, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='172.16.154.101', port=9000): Max retries exceeded with url: /hellogo/ (Caused by SSLError(SSLError(1, u'[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:727)'),))
脚本如下,使用的是http://172.16.154.101:9000可以通过浏览器连接上minio,并可以进行正常操作
# Import Minio library.
from minio import Minio
from minio.error import (ResponseError, BucketAlreadyOwnedByYou,
BucketAlreadyExists)
# Initialize minioClient with an endpoint and access/secret keys.
minioClient = Minio('172.16.154.101:9000',
access_key='AKIAIOSFODNN7EXAMPLE',