Skip to content

Instantly share code, notes, and snippets.

@Teino1978-Corp
Last active November 8, 2015 21:02
Show Gist options
  • Select an option

  • Save Teino1978-Corp/ee3b2d365bf3bfcf973c to your computer and use it in GitHub Desktop.

Select an option

Save Teino1978-Corp/ee3b2d365bf3bfcf973c to your computer and use it in GitHub Desktop.
The Java Multi-Cloud Toolkit Apache jclouds® is an open source multi-cloud toolkit for the Java platform that gives you the freedom to create applications that are portable across clouds while giving you full control to use cloud-specific features. - https://jclouds.apache.org/
ComputeService compute = ContextBuilder.newBuilder("aws-ec2")
.credentials("identity", "credential")
.buildView(ComputeServiceContext.class)
.getComputeService();
Template template = compute.templateBuilder()
.osFamily(OsFamily.UBUNTU)
.minRam(2048)
.options(inboundPorts(22, 80))
.build();
compute.createNodesInGroup("jclouds", 1, template);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment