How to use REST API to add a VM role?
I can’t use this http://msdn.microsoft.com/en-us/library/windowsazure/jj157184.aspx to delete a VM. Do I need some other steps for that?
And also I want to get some code for adding a VM Role to existed VM Role service.
I think Autoscaling will solve all of your problems here. Check out this guide to get you started.
With autoscaling, you can set up rules to add/remove instances on a deployment based on certain events or constraints. This can run on-premise or on a separate worker role. If you use WASABi, then you won’t have to mess with making the role management API calls yourself.
I hope this helps, if you have any specific questions just ask and I will do my best to answer them.
I have also posed a few errors I have encountered and the solutions for them on my blog.