I want to automatically add public key from newly created machine to github account (so it could checkout organization projects). Is there any simple way to do that? Machine OS is Debian Wheezy.
I want to automatically add public key from newly created machine to github account (so it could checkout organization projects). Is there any simple way to do that? Machine OS is Debian Wheezy.
Its not a pretty answer and requires some leg work, to automate it, you would have to implement their API. Otherwise your best option is to generate the keys and add them via the webui.
GitHub API Reference: https://developer.github.com/v3/users/keys/
This is a rough idea, and requires using OAUTH key/secret which github normally recommends against, you'd have to generate your SSH keys before you run this, adn you have to replace the contents of the key parameter, with your actual SSH public key (including ssh-rsa/ssh-dsa). Not sure if DSA even works with GitHub.
You can see more information about the GitHub API here: https://developer.github.com/v3/