Implement AutoLogin to generate/retrieve codes using a RestTemplate that automatically fetches a token

Finish implementation of https://www.pivotaltracker.com/story/show/57817784
Merge branch 'clustered_login_server' into develop