{"action":"created","issue":{"url":"https://api.github.com/repos/kubernetes/client-go/issues/242","repository_url":"https://api.github.com/repos/kubernetes/client-go","labels_url":"https://api.github.com/repos/kubernetes/client-go/issues/242/labels{/name}","comments_url":"https://api.github.com/repos/kubernetes/client-go/issues/242/comments","events_url":"https://api.github.com/repos/kubernetes/client-go/issues/242/events","html_url":"https://github.com/kubernetes/client-go/issues/242","id":242246276,"number":242,"title":"No Auth Provider found for name \"gcp\"","user":{"login":"IanLewis","id":49289,"avatar_url":"https://avatars3.githubusercontent.com/u/49289?v=3","gravatar_id":"","url":"https://api.github.com/users/IanLewis","html_url":"https://github.com/IanLewis","followers_url":"https://api.github.com/users/IanLewis/followers","following_url":"https://api.github.com/users/IanLewis/following{/other_user}","gists_url":"https://api.github.com/users/IanLewis/gists{/gist_id}","starred_url":"https://api.github.com/users/IanLewis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IanLewis/subscriptions","organizations_url":"https://api.github.com/users/IanLewis/orgs","repos_url":"https://api.github.com/users/IanLewis/repos","events_url":"https://api.github.com/users/IanLewis/events{/privacy}","received_events_url":"https://api.github.com/users/IanLewis/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2017-07-12T03:24:25Z","updated_at":"2017-07-12T15:11:14Z","closed_at":"2017-07-12T06:02:34Z","body":"For the following code I get an error when trying to connect to a GKE API server with v3.0.0.\r\n\r\nFWIW this worked in v3.0.0.beta.0\r\n\r\nI have a version of apimachinery that's about 28 days old. Could it have to do with some library incompatibility?\r\n\r\n```\r\nF0712 12:20:52.391235   71066 main.go:73] Could not create Kubernetes ThirdPartyResource API client: No Auth Provider found for name \"gcp\"\r\n```\r\n\r\n```golang\r\npackage main\r\n\r\nimport (\r\n\t\"flag\"\r\n\r\n\t\"github.com/golang/glog\"\r\n\r\n\tmetav1 \"k8s.io/apimachinery/pkg/apis/meta/v1\"\r\n\t\"k8s.io/apimachinery/pkg/runtime\"\r\n\t\"k8s.io/apimachinery/pkg/runtime/schema\"\r\n\t\"k8s.io/apimachinery/pkg/runtime/serializer\"\r\n\t\"k8s.io/client-go/kubernetes/scheme\"\r\n\t\"k8s.io/client-go/rest\"\r\n\t\"k8s.io/client-go/tools/clientcmd\"\r\n)\r\n\r\ntype Thing struct {\r\n\tmetav1.TypeMeta `json:\",inline\"`\r\n\tObjectMeta      metav1.ObjectMeta `json:\"metadata\"`\r\n}\r\n\r\n// Required to satisfy ObjectMetaAccessor interface\r\nfunc (m *Thing) GetObjectMeta() metav1.Object {\r\n\treturn &m.ObjectMeta\r\n}\r\n\r\ntype ThingList struct {\r\n\tmetav1.TypeMeta `json:\",inline\"`\r\n\tListMeta        metav1.ListMeta `json:\"metadata\"`\r\n\tItems           []Thing         `json:\"items\"`\r\n}\r\n\r\n// Required to satisfy ListMetaAccessor interface\r\nfunc (m *ThingList) GetListMeta() metav1.List {\r\n\treturn &m.ListMeta\r\n}\r\n\r\nfunc main() {\r\n\tkubeconfig := flag.String(\"kubeconfig\", \"\", \"The path to a kubeconfig. Default is in-cluster config.\")\r\n\r\n\tflag.Parse()\r\n\r\n\tconfig, err := clientcmd.BuildConfigFromFlags(\"\", *kubeconfig)\r\n\tif err != nil {\r\n\t\tglog.Exitf(\"Could not read kubeconfig %s: %v\", *kubeconfig, err)\r\n\t}\r\n\r\n\tgroupVersion := schema.GroupVersion{\r\n\t\tGroup:   \"ianlewis.org\",\r\n\t\tVersion: \"v1alpha1\",\r\n\t}\r\n\r\n\tconfig.GroupVersion = &groupVersion\r\n\tconfig.APIPath = \"/apis\"\r\n\tconfig.ContentType = runtime.ContentTypeJSON\r\n\tconfig.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs}\r\n\r\n\tschemeBuilder := runtime.NewSchemeBuilder(\r\n\t\tfunc(scheme *runtime.Scheme) error {\r\n\t\t\tscheme.AddKnownTypes(\r\n\t\t\t\tgroupVersion,\r\n\t\t\t\t&Thing{},\r\n\t\t\t\t&ThingList{},\r\n\t\t\t)\r\n\t\t\treturn nil\r\n\t\t},\r\n\t)\r\n\tschemeBuilder.AddToScheme(scheme.Scheme)\r\n\r\n\t_, err = rest.RESTClientFor(config)\r\n\r\n\tif err != nil {\r\n\t\tglog.Exitf(\"Could not create Kubernetes ThirdPartyResource API client: %v\", err)\r\n\t}\r\n\r\n\tglog.Infof(\"OK\")\r\n}\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/kubernetes/client-go/issues/comments/314800592","html_url":"https://github.com/kubernetes/client-go/issues/242#issuecomment-314800592","issue_url":"https://api.github.com/repos/kubernetes/client-go/issues/242","id":314800592,"user":{"login":"ericchiang","id":2342749,"avatar_url":"https://avatars2.githubusercontent.com/u/2342749?v=3","gravatar_id":"","url":"https://api.github.com/users/ericchiang","html_url":"https://github.com/ericchiang","followers_url":"https://api.github.com/users/ericchiang/followers","following_url":"https://api.github.com/users/ericchiang/following{/other_user}","gists_url":"https://api.github.com/users/ericchiang/gists{/gist_id}","starred_url":"https://api.github.com/users/ericchiang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ericchiang/subscriptions","organizations_url":"https://api.github.com/users/ericchiang/orgs","repos_url":"https://api.github.com/users/ericchiang/repos","events_url":"https://api.github.com/users/ericchiang/events{/privacy}","received_events_url":"https://api.github.com/users/ericchiang/received_events","type":"User","site_admin":false},"created_at":"2017-07-12T15:11:13Z","updated_at":"2017-07-12T15:11:13Z","body":"@IanLewis a few of the examples have lines like this https://github.com/kubernetes/client-go/blob/53c7adfd0294caa142d961e1f780f74081d5b15f/examples/out-of-cluster-client-configuration/main.go#L31\r\n\r\nThe actual change was made here https://github.com/kubernetes/kubernetes/pull/41532 during the 1.6 release. Are you sure this changed between v3.0.0.beta.0 and v3.0.0? I'm not seeing them imported by default in v3.0.0.beta.0\r\n\r\nhttps://github.com/kubernetes/client-go/blob/v3.0.0-beta.0/kubernetes/clientset.go\r\nhttps://github.com/kubernetes/client-go/blob/v2.0.0/kubernetes/clientset.go#L35-Lundefined\r\n\r\nI can add a changelog item for the v3.0.0.beta.0"}}
{"actor":{"display_login":"ericchiang"}}