Allow passing in a custom connection object to authenticate

this allows multiple docker remote api connections at the same time and is in line with how container and image is interfaced