Is it possible to filter out instances on a wildcard or regex? I essentially just want GCE instances, not GKE or instances provisioned by other services.
I've found that GCP service created instances have a label attached that typically starts with goog-*
. From GCP Cloud Logging I can filter these out fine but there's doesn't seem to be any support for regex in the python client.
from googleapiclient.discovery import build
service = build('compute', 'v1', credentials=credentials)
request = service.instances().aggregatedList(project="my-project", filter="labels != goog-*")