-
Notifications
You must be signed in to change notification settings - Fork 344
Description
Hello.
I am working with @vsoch on an SREGISTRY integration that uses MINIO for the storage backend with HTTPS/SSL enabled.
The environment (for testing/development) is a couple containers on a single host and looks like this:
Where the GREEN Container is our running instance of MINIO and the Two containers in purple are our MINIO clients that implement / instantiate two instances of MinioClient on startup (as i will outline below)
A bit about our minio installation
Here is the docker-compose that is in use - you can see we consuming the .mino-env on startup
- we also have done the appropriate SSL certificate (with the .PEM consisting our of cert+intermediate and the key the key)
- "know" this works, since we can see the following when we do a a simple "curl" from linux (since a browser test might be helped by baked in intermediates) we get the following (i have redacted some of our personal info)
When we login to the MINIO Web UI, we can see the following:
- we see that SSL/HTTP is working (Browser wise) (UI-pic1 below)
- we are able to see that we can create new Containers and they are written back down the backing filesystem (UI-pic2-1, UI-PIC2-2, and TERM-SHOT-1 of the filesystem after i created)
As well, here is the "mc config ls" output to show our setup defined
MC-LS-1
So we are pretty sure that the HTTPS action to/from MINIO is 'ok" from a certificate point of view.
In the SREGISTRY instantion of the two minio clients, we have the following code bit (and this is where we are seeing the "BadRequest failure " - note that we create two clients, one for External Access - which is HTTPS://ourfdqn as shown and there is another that is to use the internal link - minio - which would resolve on the docker "links" (we are not using a seperate brigde as docker in the docker compose above to link the client containers to the minio container). the idea being that the sregistries are trusted and thus would not implement https. However, it seems that with the secure=TRUE/FALSE, flag we end up in a situation where minio is bringing up a endpoint called https://127.0.0.1:9000.
[root@grid-singregistry-master sregistry]# docker logs -f 401a3d72a310
Attempting rotation of encrypted config, IAM users and policies on MinIO with newly supplied credentials
Rotation complete, please make sure to unset MINIO_ACCESS_KEY_OLD and MINIO_SECRET_KEY_OLD envs
Endpoint: https://172.17.0.4:9000 https://127.0.0.1:9000
The issue here is that for me to "make this work" i would need to put a SAN in our cert for 127.0.0.1.
CLIENT-CODE-SNIP-1
CLIENT-STACK-TRACE-1
From what i have understood, is that when we instantiate the minioClient call( either the internal or the External one) there is a connection, so im a bit stumped as to why this is failed with BadRequest on the if not makebucket command.
You will notice above that the exception shows a minioExternalClient call, that is from me trying both types of clients to see if there is anything instantiated.
I did a TCPDUMP on port 9000 on the NIC that hold the docker bridge and container traffic and no request on port 9000 ever arrived during any startup, so i suspect that the instantiation is failing of the client, but im not sure how to further in minio.py figure out if its cause of a SSL/non SSL mix up (our idea is that all communications shall be over HTTPS (internal or external as we start to distribute it).
Perhaps a silly configuration i am missing with the secure flag for the clients?
Any help would be much appreciated.
D