{"action":"created","issue":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/9728","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/9728/labels{/name}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/9728/comments","events_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/9728/events","html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/9728","id":87823605,"number":9728,"title":"Allow nodename to be != hostname, use AWS instance ID on AWS","user":{"login":"justinsb","id":100893,"avatar_url":"https://avatars.githubusercontent.com/u/100893?v=3","gravatar_id":"","url":"https://api.github.com/users/justinsb","html_url":"https://github.com/justinsb","followers_url":"https://api.github.com/users/justinsb/followers","following_url":"https://api.github.com/users/justinsb/following{/other_user}","gists_url":"https://api.github.com/users/justinsb/gists{/gist_id}","starred_url":"https://api.github.com/users/justinsb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justinsb/subscriptions","organizations_url":"https://api.github.com/users/justinsb/orgs","repos_url":"https://api.github.com/users/justinsb/repos","events_url":"https://api.github.com/users/justinsb/events{/privacy}","received_events_url":"https://api.github.com/users/justinsb/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/labels/cla:%20yes","name":"cla: yes","color":"bfe5bf"}],"state":"open","locked":false,"assignee":{"login":"dchen1107","id":7740897,"avatar_url":"https://avatars.githubusercontent.com/u/7740897?v=3","gravatar_id":"","url":"https://api.github.com/users/dchen1107","html_url":"https://github.com/dchen1107","followers_url":"https://api.github.com/users/dchen1107/followers","following_url":"https://api.github.com/users/dchen1107/following{/other_user}","gists_url":"https://api.github.com/users/dchen1107/gists{/gist_id}","starred_url":"https://api.github.com/users/dchen1107/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dchen1107/subscriptions","organizations_url":"https://api.github.com/users/dchen1107/orgs","repos_url":"https://api.github.com/users/dchen1107/repos","events_url":"https://api.github.com/users/dchen1107/events{/privacy}","received_events_url":"https://api.github.com/users/dchen1107/received_events","type":"User","site_admin":false},"milestone":null,"comments":13,"created_at":"2015-06-12T19:12:35Z","updated_at":"2015-06-17T04:01:39Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/pulls/9728","html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/9728","diff_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/9728.diff","patch_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/9728.patch"},"body":"We currently assume that a node's name is the hostname; that is natural on GCE where the name of an instance becomes the hostname, and where you refer to instances by name.  But other clouds (notably AWS) typically have synthetic instance names, and it makes more sense on those not to assume that nodename == hostname.\r\n\r\nThis has been a long time coming because we assumed in a lot of places that node-name was resolvable; but there have all been fixed now (I believe!)\r\n\r\nThe first commit here should be the most controversial: it differentiates between a nodename and a hostname.\r\n\r\nThe second commit allows a cloud provider to specify a different name for its own node, though nobody actually uses this.\r\n\r\nThe third commit wires up the previous commit to work with AWS; so AWS nodes use the instance id for the name.  This also means we don't need to query for the PublicDnsName any more, but can just retrieve instances by id.\r\n\r\nThe fourth commit just adds AWS to the list of clouds where the master kubelet does not register as a node."},"comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/comments/112644361","html_url":"https://github.com/GoogleCloudPlatform/kubernetes/pull/9728#issuecomment-112644361","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/kubernetes/issues/9728","id":112644361,"user":{"login":"justinsb","id":100893,"avatar_url":"https://avatars.githubusercontent.com/u/100893?v=3","gravatar_id":"","url":"https://api.github.com/users/justinsb","html_url":"https://github.com/justinsb","followers_url":"https://api.github.com/users/justinsb/followers","following_url":"https://api.github.com/users/justinsb/following{/other_user}","gists_url":"https://api.github.com/users/justinsb/gists{/gist_id}","starred_url":"https://api.github.com/users/justinsb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justinsb/subscriptions","organizations_url":"https://api.github.com/users/justinsb/orgs","repos_url":"https://api.github.com/users/justinsb/repos","events_url":"https://api.github.com/users/justinsb/events{/privacy}","received_events_url":"https://api.github.com/users/justinsb/received_events","type":"User","site_admin":false},"created_at":"2015-06-17T04:01:39Z","updated_at":"2015-06-17T04:01:39Z","body":"I think the risk is low for non-AWS clouds: I've tried to separate it out and make it (I hope) clearly a no-op for anything non-AWS.  Though there are two variables (nodename and hostname), they are equal everywhere but on AWS.\r\n\r\nFor AWS, there is obviously more risk, but the upside is that we get to use the natural identifier (for AWS users, who expect the instance ID), and that we dump matching-by-primary-dns-name.  I believe I have made that work, but it is matching on a secondary index without the same uniqueness constraints as the instance id has.\r\n\r\nThere are some other PRs that also rely on this, including the big one: running the minion nodes in an auto scaling group (#9720 then #9921). \r\n\r\nI have tried to make it acceptable risk to other clouds.  It is higher risk on AWS, but we unlock huge pieces of (last-minute) functionality.\r\n\r\nWe can also have those PRs without this, though I have to rework them to not be based on this, they would have to go through the translation layer.  If we can't have this one, but the others are a possibility, let's decide that quickly so I can \"de-base\" them :-)"}}