diff --git a/apis/cloudsigma/src/main/java/org/jclouds/cloudsigma/CloudSigmaPropertiesBuilder.java b/apis/cloudsigma/src/main/java/org/jclouds/cloudsigma/CloudSigmaPropertiesBuilder.java index 57cd5b1c5e..bdcb5128ba 100644 --- a/apis/cloudsigma/src/main/java/org/jclouds/cloudsigma/CloudSigmaPropertiesBuilder.java +++ b/apis/cloudsigma/src/main/java/org/jclouds/cloudsigma/CloudSigmaPropertiesBuilder.java @@ -37,6 +37,10 @@ public class CloudSigmaPropertiesBuilder extends PropertiesBuilder { Properties properties = super.defaultProperties(); properties.setProperty(PROPERTY_API_VERSION, "1.0"); properties.setProperty(PROPERTY_VNC_PASSWORD, "IL9vs34d"); + // passwords are set post-boot, so auth failures are possible + // from a race condition applying the password set script + properties.setProperty("jclouds.ssh.max-retries", "7"); + properties.setProperty("jclouds.ssh.retry-auth", "true"); return properties; } diff --git a/apis/cloudsigma/src/main/java/org/jclouds/cloudsigma/compute/functions/PreinstalledDiskToImage.java b/apis/cloudsigma/src/main/java/org/jclouds/cloudsigma/compute/functions/PreinstalledDiskToImage.java index c64561896e..5439b5d0ad 100644 --- a/apis/cloudsigma/src/main/java/org/jclouds/cloudsigma/compute/functions/PreinstalledDiskToImage.java +++ b/apis/cloudsigma/src/main/java/org/jclouds/cloudsigma/compute/functions/PreinstalledDiskToImage.java @@ -28,7 +28,6 @@ import org.jclouds.compute.domain.OperatingSystem; import org.jclouds.compute.domain.OperatingSystem.Builder; import org.jclouds.compute.domain.OsFamilyVersion64Bit; import org.jclouds.domain.Location; -import org.jclouds.domain.LoginCredentials; import com.google.common.base.Function; import com.google.common.base.Supplier; @@ -61,7 +60,6 @@ public class PreinstalledDiskToImage implements Function { .family(parsed.family); return new ImageBuilder().ids(drive.getUuid()) .userMetadata(ImmutableMap. of("size", drive.getSize() / 1024 / 1024 / 1024 + "")) - .defaultCredentials(new LoginCredentials("cloudsigma", "cloudsigma", null, true)) .location(locationSupplier.get()).name(drive.getName()).description(description) .operatingSystem(builder.build()).version("").build(); } diff --git a/providers/cloudsigma-zrh/pom.xml b/providers/cloudsigma-zrh/pom.xml index 2efb74f244..0358a03522 100644 --- a/providers/cloudsigma-zrh/pom.xml +++ b/providers/cloudsigma-zrh/pom.xml @@ -34,7 +34,7 @@ bundle - https://api.cloudsigma.com + https://api.zrh.cloudsigma.com 1.0 FIXME FIXME diff --git a/providers/cloudsigma-zrh/src/main/java/org/jclouds/cloudsigma/CloudSigmaZurichPropertiesBuilder.java b/providers/cloudsigma-zrh/src/main/java/org/jclouds/cloudsigma/CloudSigmaZurichPropertiesBuilder.java index eb3df43f86..7900f4beaa 100644 --- a/providers/cloudsigma-zrh/src/main/java/org/jclouds/cloudsigma/CloudSigmaZurichPropertiesBuilder.java +++ b/providers/cloudsigma-zrh/src/main/java/org/jclouds/cloudsigma/CloudSigmaZurichPropertiesBuilder.java @@ -33,7 +33,7 @@ public class CloudSigmaZurichPropertiesBuilder extends CloudSigmaPropertiesBuild protected Properties defaultProperties() { Properties properties = super.defaultProperties(); properties.setProperty(PROPERTY_ISO3166_CODES, "CH-ZH"); - properties.setProperty(PROPERTY_ENDPOINT, "https://api.cloudsigma.com"); + properties.setProperty(PROPERTY_ENDPOINT, "https://api.zrh.cloudsigma.com"); return properties; } diff --git a/providers/cloudsigma-zrh/src/main/java/org/jclouds/cloudsigma/CloudSigmaZurichProviderMetadata.java b/providers/cloudsigma-zrh/src/main/java/org/jclouds/cloudsigma/CloudSigmaZurichProviderMetadata.java index 6e35f119a2..8f809eea34 100644 --- a/providers/cloudsigma-zrh/src/main/java/org/jclouds/cloudsigma/CloudSigmaZurichProviderMetadata.java +++ b/providers/cloudsigma-zrh/src/main/java/org/jclouds/cloudsigma/CloudSigmaZurichProviderMetadata.java @@ -86,7 +86,7 @@ public class CloudSigmaZurichProviderMetadata extends BaseProviderMetadata { */ @Override public URI getConsole() { - return URI.create("https://cs.cloudsigma.com/"); + return URI.create("https://gui.zrh.cloudsigma.com/"); } /** * {@inheritDoc} diff --git a/providers/cloudsigma-zrh/src/test/java/org/jclouds/cloudsigma/compute/CloudSigmaZurichTemplateBuilderLiveTest.java b/providers/cloudsigma-zrh/src/test/java/org/jclouds/cloudsigma/compute/CloudSigmaZurichTemplateBuilderLiveTest.java index 789b148d72..733b490404 100644 --- a/providers/cloudsigma-zrh/src/test/java/org/jclouds/cloudsigma/compute/CloudSigmaZurichTemplateBuilderLiveTest.java +++ b/providers/cloudsigma-zrh/src/test/java/org/jclouds/cloudsigma/compute/CloudSigmaZurichTemplateBuilderLiveTest.java @@ -52,19 +52,17 @@ public class CloudSigmaZurichTemplateBuilderLiveTest extends BaseTemplateBuilder public boolean apply(OsFamilyVersion64Bit input) { switch (input.family) { case UBUNTU: - return (input.version.equals("11.04") || input.version.equals("10.04") && !input.is64Bit) - || (input.version.equals("10.10") && input.is64Bit) || input.version.equals(""); + return (input.version.equals("") || input.version.matches("1[01].04") || input.version.equals("10.10")) + && input.is64Bit; case SOLARIS: - return !input.is64Bit; + return input.version.equals("") && input.is64Bit; case DEBIAN: - return input.is64Bit; + return (input.version.equals("") || input.version.equals("5.0")) && input.is64Bit; case CENTOS: - return input.version.equals("5.5") || input.version.equals("") - || (input.version.matches("5.0") && input.is64Bit) - || (input.version.matches("6.0") && !input.is64Bit); + return input.version.equals("") || (input.version.equals("5.7") && input.is64Bit); case WINDOWS: - return input.version.equals("2008 R2") || (input.version.equals("2008") && !input.is64Bit) - || input.version.equals("") || (input.version.equals("2003")); + return input.version.equals("") + || ((input.version.equals("2008") || input.version.equals("2003")) && !input.is64Bit); default: return false; } @@ -78,9 +76,9 @@ public class CloudSigmaZurichTemplateBuilderLiveTest extends BaseTemplateBuilder Template defaultTemplate = context.getComputeService().templateBuilder().build(); assertEquals(defaultTemplate.getImage().getOperatingSystem().getVersion(), "11.04"); assertEquals(defaultTemplate.getImage().getOperatingSystem().is64Bit(), true); - assertEquals(defaultTemplate.getImage().getId(), "7fad4fe1-daf3-4cb8-a847-082aae4d8506"); + assertEquals(defaultTemplate.getImage().getId(), "331f8cff-99c9-4fa9-9069-8f699795ef7e"); assertEquals(defaultTemplate.getImage().getOperatingSystem().getFamily(), OsFamily.UBUNTU); - assertEquals(defaultTemplate.getImage().getDefaultCredentials().identity, "cloudsigma"); + assertEquals(defaultTemplate.getImage().getDefaultCredentials().identity, "root"); assertEquals(getCores(defaultTemplate.getHardware()), 1.0d); }