TritonDataCenter / sdc-docker

Docker Engine for Triton
Mozilla Public License 2.0
183 stars 49 forks source link

required version in endpoint paths #46

Closed codechaotic closed 9 years ago

codechaotic commented 9 years ago

In working with the Triton Elastic Container Service I struggled with what looks like an undocumented divergence of sdc-docker API from the vanilla Docker Remote API. To make it very explicit, the Docker documentation on the Remote API mentions that

Calling /info is the same as calling /v1.19/info

and yet by quick demonstration this is not the case when working with Joyent's Docker Remote API

This works:

curl https://us-east-1.docker.joyent.com:2376/v1.19/info --cert cert.pem \
       --key key.pem --cacert ca.pem

But this does not:

curl https://us-east-1.docker.joyent.com:2376/info  --cert cert.pem \
       --key key.pem --cacert ca.pem

This divergence causes some challenges when attempting to use some tools which transparently assume the above equivalence, and for this reason I believe it should be added to the list of divergences (or if it's simple enough to do, rectified).

codechaotic commented 9 years ago

Related to apocas/dockerode#154

twhiteman commented 9 years ago

Thanks for the report. This particular issue was fixed recently, see: https://smartos.org/bugview/DOCKER-441

Currently the fix has only been rolled out to us-east-3b:

curl https://us-east-3b.docker.joyent.com:2376/v1.19/info --cert cert.pem \
       --key key.pem --cacert ca.pem

and will be rolled out to the other datacenters (like us-east1, etc...) soon - though I'm sorry I don't have an exact date for when this update will occur in each datacenter.

codechaotic commented 9 years ago

That's awesome even if the patch is only eventually useful. Eventually is good enough and I'm very glad to hear the fix is already out there. Thanks for the feedback.