mirror of https://github.com/apache/jclouds.git
Issue 712:add support for CloudSigma Las Vegas
This commit is contained in:
parent
9adcd47bdb
commit
809a1b051c
|
@ -15,13 +15,13 @@ check out our examples site! https://github.com/jclouds/jclouds-examples
|
|||
|
||||
our compute api supports: aws-ec2, gogrid, cloudservers-us, stub (in-memory), deltacloud,
|
||||
cloudservers-uk, vcloud (generic), ec2 (generic), byon, nova,
|
||||
trmk-ecloud, trmk-vcloudexpress, eucalyptus (generic),
|
||||
cloudsigma-zrh, elasticstack(generic), go2cloud-jhb1,
|
||||
trmk-ecloud, trmk-vcloudexpress, eucalyptus (generic)
|
||||
cloudsigma-zrh, elasticstack(generic), go2cloud-jhb1, cloudsigma-lvs,
|
||||
bluelock-vcloud-zone01, stratogen-vcloud-mycloud, rimuhosting,
|
||||
slicehost, eucalyptus-partnercloud-ec2, elastichosts-lon-p (Peer 1),
|
||||
elastichosts-sat-p (Peer 1), elastichosts-lon-b (BlueSquare),
|
||||
openhosting-east1, serverlove-z1-man, skalicloud-sdg-my,
|
||||
greenhousedata-element-vcloud, softlayer
|
||||
greenhousedata-element-vcloud, softlayer, cloudsigma (generic)
|
||||
|
||||
* note * the pom dependency org.jclouds/jclouds-allcompute gives you access to
|
||||
to all of these providers
|
||||
|
|
|
@ -95,6 +95,11 @@
|
|||
<artifactId>vcloud</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jclouds.api</groupId>
|
||||
<artifactId>cloudsigma</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jclouds.provider</groupId>
|
||||
<artifactId>trmk-vcloudexpress</artifactId>
|
||||
|
@ -165,6 +170,11 @@
|
|||
<artifactId>cloudsigma-zrh</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jclouds.provider</groupId>
|
||||
<artifactId>cloudsigma-lvs</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jclouds.provider</groupId>
|
||||
<artifactId>go2cloud-jhb1</artifactId>
|
||||
|
|
|
@ -0,0 +1,139 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
|
||||
Licensed to jclouds, Inc. (jclouds) under one or more
|
||||
contributor license agreements. See the NOTICE file
|
||||
distributed with this work for additional information
|
||||
regarding copyright ownership. jclouds licenses this file
|
||||
to you under the Apache License, Version 2.0 (the
|
||||
"License"); you may not use this file except in compliance
|
||||
with the License. You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing,
|
||||
software distributed under the License is distributed on an
|
||||
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, either express or implied. See the License for the
|
||||
specific language governing permissions and limitations
|
||||
under the License.
|
||||
|
||||
-->
|
||||
<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/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>org.jclouds</groupId>
|
||||
<artifactId>jclouds-project</artifactId>
|
||||
<version>1.2.0-SNAPSHOT</version>
|
||||
<relativePath>../../project/pom.xml</relativePath>
|
||||
</parent>
|
||||
<groupId>org.jclouds.api</groupId>
|
||||
<artifactId>cloudsigma</artifactId>
|
||||
<name>jclouds CloudSigma API</name>
|
||||
<description>ComputeService binding to the CloudSigma API</description>
|
||||
<packaging>bundle</packaging>
|
||||
|
||||
<properties>
|
||||
<test.cloudsigma.endpoint>https://api.cloudsigma.com</test.cloudsigma.endpoint>
|
||||
<test.cloudsigma.apiversion>1.0</test.cloudsigma.apiversion>
|
||||
<test.cloudsigma.identity>FIXME</test.cloudsigma.identity>
|
||||
<test.cloudsigma.credential>FIXME</test.cloudsigma.credential>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.jclouds</groupId>
|
||||
<artifactId>jclouds-compute</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jclouds.driver</groupId>
|
||||
<artifactId>jclouds-sshj</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jclouds</groupId>
|
||||
<artifactId>jclouds-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<type>test-jar</type>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jclouds</groupId>
|
||||
<artifactId>jclouds-compute</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<type>test-jar</type>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jclouds.driver</groupId>
|
||||
<artifactId>jclouds-log4j</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<profiles>
|
||||
<profile>
|
||||
<id>live</id>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>integration</id>
|
||||
<phase>integration-test</phase>
|
||||
<goals>
|
||||
<goal>test</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<systemProperties>
|
||||
<property>
|
||||
<name>test.cloudsigma.endpoint</name>
|
||||
<value>${test.cloudsigma.endpoint}</value>
|
||||
</property>
|
||||
<property>
|
||||
<name>test.cloudsigma.apiversion</name>
|
||||
<value>${test.cloudsigma.apiversion}</value>
|
||||
</property>
|
||||
<property>
|
||||
<name>test.cloudsigma.identity</name>
|
||||
<value>${test.cloudsigma.identity}</value>
|
||||
</property>
|
||||
<property>
|
||||
<name>test.cloudsigma.credential</name>
|
||||
<value>${test.cloudsigma.credential}</value>
|
||||
</property>
|
||||
<property>
|
||||
<name>jclouds.compute.blacklist-nodes</name>
|
||||
<value>${jclouds.compute.blacklist-nodes}</value>
|
||||
</property>
|
||||
</systemProperties>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</profile>
|
||||
</profiles>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.felix</groupId>
|
||||
<artifactId>maven-bundle-plugin</artifactId>
|
||||
<configuration>
|
||||
<instructions>
|
||||
<Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
|
||||
<Export-Package>org.jclouds.cloudsigma.*;version="${project.version}"</Export-Package>
|
||||
<Import-Package>org.jclouds.*;version="${project.version}",*</Import-Package>
|
||||
</instructions>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
|
@ -42,6 +42,7 @@ import org.jclouds.compute.config.ComputeServiceAdapterContextModule;
|
|||
import org.jclouds.compute.domain.Hardware;
|
||||
import org.jclouds.compute.domain.Image;
|
||||
import org.jclouds.compute.domain.NodeMetadata;
|
||||
import org.jclouds.compute.domain.OsFamily;
|
||||
import org.jclouds.compute.domain.OsFamilyVersion64Bit;
|
||||
import org.jclouds.compute.domain.TemplateBuilder;
|
||||
import org.jclouds.compute.domain.Volume;
|
||||
|
@ -76,11 +77,7 @@ public class CloudSigmaComputeServiceContextModule
|
|||
|
||||
@Override
|
||||
protected TemplateBuilder provideTemplate(Injector injector, TemplateBuilder template) {
|
||||
// until there is a way to query by drive info that can suggest which
|
||||
// drives are ssh boot
|
||||
return template.imageId("f3c7c665-cd54-4a78-8fd2-7ec2f028cf29").minRam(1024);
|
||||
// return
|
||||
// template.osFamily(UBUNTU).osVersionMatches("1[10].[10][04]").os64Bit(true).minRam(1024);
|
||||
return template.osFamily(OsFamily.UBUNTU).imageNameMatches(".*automated SSH Access.*");
|
||||
}
|
||||
|
||||
@SuppressWarnings({ "unchecked", "rawtypes" })
|
|
@ -651,6 +651,8 @@ public class CloudSigmaAsyncClientTest extends RestClientTest<CloudSigmaAsyncCli
|
|||
|
||||
@Override
|
||||
public RestContextSpec<CloudSigmaClient, CloudSigmaAsyncClient> createContextSpec() {
|
||||
return new RestContextFactory().createContextSpec("cloudsigma-zrh", "foo", "bar", new Properties());
|
||||
Properties props = new Properties();
|
||||
props.setProperty("cloudsigma.endpoint", "https://api.cloudsigma.com");
|
||||
return new RestContextFactory().createContextSpec("cloudsigma", "foo", "bar", props);
|
||||
}
|
||||
}
|
|
@ -78,11 +78,12 @@ public class CloudSigmaClientLiveTest {
|
|||
protected long driveSize = 8 * 1024 * 1024 * 1024l;
|
||||
protected int maxDriveImageTime = 300;
|
||||
protected String vncPassword = "Il0veVNC";
|
||||
protected String bootDrive = "f3c7c665-cd54-4a78-8fd2-7ec2f028cf29";
|
||||
protected CloudSigmaClient client;
|
||||
protected RestContext<CloudSigmaClient, CloudSigmaAsyncClient> context;
|
||||
protected Predicate<IPSocket> socketTester;
|
||||
|
||||
protected String provider = "cloudsigma-zrh";
|
||||
protected String provider = "cloudsigma";
|
||||
protected String identity;
|
||||
protected String credential;
|
||||
protected String endpoint;
|
||||
|
@ -460,7 +461,7 @@ public class CloudSigmaClientLiveTest {
|
|||
|
||||
protected void prepareDrive() {
|
||||
client.destroyDrive(drive.getUuid());
|
||||
drive = client.cloneDrive("f3c7c665-cd54-4a78-8fd2-7ec2f028cf29", drive.getName(),
|
||||
drive = client.cloneDrive(bootDrive, drive.getName(),
|
||||
new CloneDriveOptions().size(driveSize));
|
||||
assert driveNotClaimed.apply(drive) : client.getDriveInfo(drive.getUuid());
|
||||
System.err.println("after prepare" + client.getDriveInfo(drive.getUuid()));
|
|
@ -32,7 +32,7 @@ import com.google.inject.Module;
|
|||
@Test(groups = "live")
|
||||
public class CloudSigmaComputeServiceLiveTest extends BaseComputeServiceLiveTest {
|
||||
public CloudSigmaComputeServiceLiveTest() {
|
||||
provider = "cloudsigma-zrh";
|
||||
provider = "cloudsigma";
|
||||
}
|
||||
|
||||
@Override
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue