I'm seeing a lot of docker related plugins in the community. They are already popular, and becoming more popular for obvious reasons.
So I started looking into how to improve the story around Jenkins and Docker, and I talked to some of you that a low-hanging fruit is to provide some common credentials configuration across those docker related plugins, so that people won't have to configure them repeatedly.
The plugin contains two sets of credential+endpoint information, one for talking to docker daemon and one for talking to docker registry. For registry, the credential is a token (and username+password for DockerHub.) For daemon, the credential is SSL client authentication stuff.
The endpoint combines the credential with the URL/URI of the registry/daemon. They expose a method that helps you invoke docker CLI in the right environment, an it hides the details of making key materials and tokens available to docker CLI. See
some code example for details.
The endpoints are Describable, so that you can insert them into your builder/publisher etc, and it provides all the necessary configuration GUI.
I think it has enough shape in it to get the idea across, and so I wanted to have a conversation about that here before I release 1.0 and commit to the backward compatibility. I'll reach out to the folks who maintain popular docker plugins, but your thoughts are appreciated.
Just in case you want to play with the signature and so on, I published 1.0-alpha-1, but it's still missing a number of things to make it actually runnable, such as proper Descriptor implementations and config UIs.