{"action":"closed","issue":{"url":"https://api.github.com/repos/hashicorp/consul-template/issues/259","labels_url":"https://api.github.com/repos/hashicorp/consul-template/issues/259/labels{/name}","comments_url":"https://api.github.com/repos/hashicorp/consul-template/issues/259/comments","events_url":"https://api.github.com/repos/hashicorp/consul-template/issues/259/events","html_url":"https://github.com/hashicorp/consul-template/issues/259","id":70152334,"number":259,"title":"get the last registered node of a service","user":{"login":"ezyk","id":11630853,"avatar_url":"https://avatars.githubusercontent.com/u/11630853?v=3","gravatar_id":"","url":"https://api.github.com/users/ezyk","html_url":"https://github.com/ezyk","followers_url":"https://api.github.com/users/ezyk/followers","following_url":"https://api.github.com/users/ezyk/following{/other_user}","gists_url":"https://api.github.com/users/ezyk/gists{/gist_id}","starred_url":"https://api.github.com/users/ezyk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ezyk/subscriptions","organizations_url":"https://api.github.com/users/ezyk/orgs","repos_url":"https://api.github.com/users/ezyk/repos","events_url":"https://api.github.com/users/ezyk/events{/privacy}","received_events_url":"https://api.github.com/users/ezyk/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-04-22T15:02:14Z","updated_at":"2015-05-11T14:34:18Z","closed_at":"2015-05-11T14:34:18Z","body":"Hello,\r\ni am using \r\n````\r\n{{range service \"web\"}}\r\n    server  {{.Address}}:{{.Port}};\r\n{{end}}\r\n```\r\nTo iterate all the nodes of the of the service *web*. The array that the *service* function returns how  is it ordered?  Can i get the last registered node of the service? I am using consul-template to rewrite an nginx config file. Every time a new docker container is created , i want the nginx proxy to point to the new container. \r\n\r\nThanks"}}