{"action":"created","issue":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/3275","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/3275/labels{/name}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/3275/comments","events_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/3275/events","html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/3275","id":53668337,"number":3275,"title":"add kubectl config","user":{"login":"deads2k","id":8225098,"avatar_url":"https://avatars.githubusercontent.com/u/8225098?v=3","gravatar_id":"","url":"https://api.github.com/users/deads2k","html_url":"https://github.com/deads2k","followers_url":"https://api.github.com/users/deads2k/followers","following_url":"https://api.github.com/users/deads2k/following{/other_user}","gists_url":"https://api.github.com/users/deads2k/gists{/gist_id}","starred_url":"https://api.github.com/users/deads2k/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/deads2k/subscriptions","organizations_url":"https://api.github.com/users/deads2k/orgs","repos_url":"https://api.github.com/users/deads2k/repos","events_url":"https://api.github.com/users/deads2k/events{/privacy}","received_events_url":"https://api.github.com/users/deads2k/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"jlowdermilk","id":2101035,"avatar_url":"https://avatars.githubusercontent.com/u/2101035?v=3","gravatar_id":"","url":"https://api.github.com/users/jlowdermilk","html_url":"https://github.com/jlowdermilk","followers_url":"https://api.github.com/users/jlowdermilk/followers","following_url":"https://api.github.com/users/jlowdermilk/following{/other_user}","gists_url":"https://api.github.com/users/jlowdermilk/gists{/gist_id}","starred_url":"https://api.github.com/users/jlowdermilk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jlowdermilk/subscriptions","organizations_url":"https://api.github.com/users/jlowdermilk/orgs","repos_url":"https://api.github.com/users/jlowdermilk/repos","events_url":"https://api.github.com/users/jlowdermilk/events{/privacy}","received_events_url":"https://api.github.com/users/jlowdermilk/received_events","type":"User","site_admin":false},"milestone":null,"comments":5,"created_at":"2015-01-07T19:03:55Z","updated_at":"2015-01-12T18:19:08Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/3275","html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/3275","diff_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/3275.diff","patch_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/3275.patch"},"body":"This adds `kubectl config <subcommand>` to set values inside of .kubeconfig files.\r\n\r\nFor example:\r\n```\r\n$kubectl config set-credentials myself --auth-path=path/to/my/existing/auth-file\r\n$kubectl config set-cluster local-server --server=http://localhost:8080\r\n$kubectl config set-context default-context --cluster=local-server --user=myself\r\n$kubectl config use-context default-context\r\n$kubectl config set contexts.default-context.namespace the-right-prefix\r\n$kubectl config view\r\n```\r\nproduces this output\r\n```\r\nclusters:\r\n  local-server:\r\n    server: http://localhost:8080\r\ncontexts:\r\n  default-context:\r\n    cluster: local-server\r\n    namespace: the-right-prefix\r\n    user: myself\r\ncurrent-context: default-context\r\npreferences: {}\r\nusers:\r\n  myself:\r\n    auth-path: path/to/my/existing/auth-file\r\n\r\n```\r\nand a .kubeconfig file that looks like this\r\n```\r\napiVersion: v1\r\nclusters:\r\n- cluster:\r\n    server: http://localhost:8080\r\n  name: local-server\r\ncontexts:\r\n- context:\r\n    cluster: local-server\r\n    namespace: the-right-prefix\r\n    user: myself\r\n  name: default-context\r\ncurrent-context: default-context\r\nkind: Config\r\npreferences: {}\r\nusers:\r\n- name: myself\r\n  user:\r\n    auth-path: path/to/my/existing/auth-file\r\n```"},"comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/comments/69617409","html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/3275#issuecomment-69617409","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/3275","id":69617409,"user":{"login":"jlowdermilk","id":2101035,"avatar_url":"https://avatars.githubusercontent.com/u/2101035?v=3","gravatar_id":"","url":"https://api.github.com/users/jlowdermilk","html_url":"https://github.com/jlowdermilk","followers_url":"https://api.github.com/users/jlowdermilk/followers","following_url":"https://api.github.com/users/jlowdermilk/following{/other_user}","gists_url":"https://api.github.com/users/jlowdermilk/gists{/gist_id}","starred_url":"https://api.github.com/users/jlowdermilk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jlowdermilk/subscriptions","organizations_url":"https://api.github.com/users/jlowdermilk/orgs","repos_url":"https://api.github.com/users/jlowdermilk/repos","events_url":"https://api.github.com/users/jlowdermilk/events{/privacy}","received_events_url":"https://api.github.com/users/jlowdermilk/received_events","type":"User","site_admin":false},"created_at":"2015-01-12T18:19:08Z","updated_at":"2015-01-12T18:19:08Z","body":"Still one minor nit about current vs specified in the help text of \"config view\". Otherwise lgtm"}}