Create Virtual Machine on Azure with Java SDK -


i need create virtual machine azure java sdk. integrated maven dependencies project. need simple tutorial. can me?

thanks

recently azure has rolled out [java api (1.0.0) ][1]as stable release. follow 1.0.0 sdk in creating virtual machine.

 1. create azure authentication file credentials  subscription=<enter_subscription> client=<enter_client> key=<enter_key> tenant=<enter_tenant> managementuri=https\://management.core.windows.net/ baseurl=https\://management.azure.com/ authurl=https\://login.windows.net/ graphurl=https\://graph.windows.net/  2. azure client perform operation in azure  `final file credfile = new file("/users/risanand/cliqr.azureauth");  azure azure = azure.configure()  .withloglevel(loglevel.basic)  .authenticate(credfile)  .withdefaultsubscription();`  3. create virtual machine     `virtualmachine windowsvm = azure.virtualmachines().define("vmname")     .withregion("regionname")     .withnewresourcegroup("resourcegroupname")     .withnewprimarynetwork("10.0.0.0/28")     .withprimaryprivateipaddressdynamic()     .withoutprimarypublicipaddress()                        .withadminusername(username)     .withadminpassword(password)     .withnewdatadisk(10)     .withsize(virtualmachinesizetypes.standard_d3_v2)     .create();`      [1]: https://github.com/azure/azure-sdk-for-java 

Comments

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -