Package org.jclouds.ibm.smartcloud.options

Examples of org.jclouds.ibm.smartcloud.options.CreateInstanceOptions


   public void testCreateInstanceInLocationWithOptions() throws SecurityException, NoSuchMethodException, IOException {
      Method method = IBMSmartCloudAsyncClient.class.getMethod("createInstanceInLocation", String.class, String.class,
               String.class, String.class, CreateInstanceOptions[].class);
      GeneratedHttpRequest httpRequest = processor.createRequest(method, "location", "name", "22", "instanceType",
               new CreateInstanceOptions().staticIP("1").authorizePublicKey("MOO").mountVolume("2", "/mnt")
                        .configurationData(
                                 ImmutableMap.of("insight_admin_password", "myPassword1", "db2_admin_password",
                                          "myPassword2", "report_user_password", "myPassword3")));

      assertRequestLineEquals(httpRequest,
View Full Code Here


   }

   @Override
   public NodeMetadata createNodeWithGroupEncodedIntoName(String group, String name, Template template) {
      IBMSmartCloudTemplateOptions templateOptions = template.getOptions().as(IBMSmartCloudTemplateOptions.class);
      CreateInstanceOptions options = authorizePublicKey(templateOptions.getKeyPair()).isMiniEphemeral(
               IBMSmartCloudTemplateOptions.class.cast(template.getOptions()).isMiniEphemeral());
      Instance instance = client.createInstanceInLocation(template.getLocation().getId(), name, template.getImage()
               .getProviderId(), template.getHardware().getProviderId(), options);
      return instanceToNodeMetadata.apply(instance);
   }
View Full Code Here

TOP

Related Classes of org.jclouds.ibm.smartcloud.options.CreateInstanceOptions

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.