This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Set; | |
import java.lang.Thread.UncaughtExceptionHandler; | |
import org.jclouds.ContextBuilder; | |
import org.jclouds.compute.ComputeService; | |
import org.jclouds.compute.ComputeServiceContext; | |
import org.jclouds.compute.domain.ComputeMetadata; | |
import org.jclouds.openstack.nova.v2_0.features.ImageApi; | |
import org.jclouds.openstack.nova.v2_0.domain.Image; | |
import org.jclouds.rest.RestContext; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ pwd | |
/Users/phymata/test/jclouds-test | |
$ ls | |
JCloudsLoggingExample.java JCloudsTest.java lib project.clj | |
JCloudsOpenStack.java lein.sh logback.xml | |
$ javac -cp ".:lib/*" JCloudsOpenStack.java | |
$ java -cp ".:lib/*" JCloudsOpenStack |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.rackspace; | |
import org.jclouds.ContextBuilder; | |
import org.jclouds.logging.slf4j.config.SLF4JLoggingModule; | |
import org.jclouds.openstack.keystone.v2_0.AuthenticationApi; | |
import org.jclouds.openstack.keystone.v2_0.KeystoneApi; | |
import org.jclouds.openstack.keystone.v2_0.KeystoneAsyncApi; | |
import org.jclouds.openstack.keystone.v2_0.domain.Access; | |
import org.jclouds.openstack.keystone.v2_0.domain.PasswordCredentials; | |
import org.jclouds.rest.RestContext; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.jclouds.examples.rackspace; | |
import java.lang.Thread.UncaughtExceptionHandler; | |
import org.jclouds.ContextBuilder; | |
import org.jclouds.compute.ComputeService; | |
import org.jclouds.compute.ComputeServiceContext; | |
import org.jclouds.logging.slf4j.config.SLF4JLoggingModule; | |
import org.jclouds.openstack.keystone.v2_0.domain.Access; | |
import org.jclouds.openstack.keystone.v2_0.domain.PasswordCredentials; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17:16:25,112 |-INFO in ch.qos.logback.classic.LoggerContext[default] - Could NOT find resource [logback.groovy] | |
17:16:25,115 |-INFO in ch.qos.logback.classic.LoggerContext[default] - Could NOT find resource [logback-test.xml] | |
17:16:25,115 |-INFO in ch.qos.logback.classic.LoggerContext[default] - Found resource [logback.xml] at [file:/Users/ever5257/dev/rackspace/jclouds/apis/openstack-keystone/target/test-classes/logback.xml] | |
17:16:25,119 |-WARN in ch.qos.logback.classic.LoggerContext[default] - Resource [logback.xml] occurs multiple times on the classpath. | |
17:16:25,119 |-WARN in ch.qos.logback.classic.LoggerContext[default] - Resource [logback.xml] occurs at [file:/Users/ever5257/dev/rackspace/jclouds/apis/openstack-keystone/target/test-classes/logback.xml] | |
17:16:25,119 |-WARN in ch.qos.logback.classic.LoggerContext[default] - Resource [logback.xml] occurs at [file:/Users/ever5257/dev/rackspace/jclouds/compute/target/test-classes/logback.xml] | |
17:16:25,210 |-INFO in ch.qos.logback.classic.joran.action.Configu |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ADMIN_PASSWORD=devstack | |
MYSQL_PASSWORD=devstack | |
RABBIT_PASSWORD=devstack | |
SERVICE_PASSWORD=devstack | |
SERVICE_TOKEN=devstack | |
FLAT_INTERFACE=br100 | |
PUBLIC_INTERFACE=eth1 | |
VOLUME_BACKING_FILE_SIZE=5120M |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ADMIN_PASSWORD=devstack | |
MYSQL_PASSWORD=devstack | |
RABBIT_PASSWORD=devstack | |
SERVICE_PASSWORD=devstack | |
SERVICE_TOKEN=devstack | |
FLAT_INTERFACE=br100 | |
PUBLIC_INTERFACE=eth1 | |
VOLUME_BACKING_FILE_SIZE=5120M |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<properties> | |
<jclouds.version>1.6.1-incubating</jclouds.version> | |
</properties> | |
<groupId>org.apache.jclouds.examples</groupId> | |
<artifactId>rackspace-examples</artifactId> | |
<version>0.0.1-SNAPSHOT</version> | |
<dependencies> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import static com.google.common.base.Charsets.UTF_8; | |
import static com.google.common.collect.Lists.newArrayList; | |
import static com.google.common.collect.Maps.newHashMap; | |
import static java.util.concurrent.TimeUnit.SECONDS; | |
import static org.jclouds.scriptbuilder.domain.Statements.exec; | |
import static org.jclouds.util.Predicates2.retry; | |
import java.io.File; | |
import java.io.IOException; | |
import java.util.List; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void main(String[] args) { | |
JCloudsWorkshop jcloudsWorkshop = new JCloudsWorkshop(); | |
try { | |
jcloudsWorkshop.init(); | |
jcloudsWorkshop.createNodes(); | |
jcloudsWorkshop.configureAndStartWebservers(); | |
jcloudsWorkshop.detectExtensions(); | |
jcloudsWorkshop.printResults(); | |
// jcloudsWorkshop.deleteNodes(); |