Google API Client: Container Registry API Python

10/4/2016

I want to get a list of images in the Google Container Engine using Python, and eventually, start an instance of one of them. I know there's a gcloud command to list images, but is this possible to do using the googleapiclient?

I imagine it would be something like this:

from googleapiclient.discovery import build
gce_service =  build('container', 'v1')
# Now what?
-- speedplane
google-api-client
google-container-registry
google-kubernetes-engine
python

1 Answer

10/5/2016

For image listing,

Google Container Registry is a Docker Registry API so you probably won't be able to list images through googleapiclient.

Something that uses the Docker Registry API like https://pypi.python.org/pypi/docker-registry-client/1.0 may be worth a try but I have not tried it.

-- Nghia Tran
Source: StackOverflow