jclouds-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Phillips <notificati...@github.com>
Subject Re: [jclouds-examples] bump jclouds version to 1.9.0 (#72)
Date Wed, 01 Apr 2015 01:45:33 GMT
> @@ -160,12 +160,18 @@ public static void main(String[] args) {
>              Statement bootInstructions = AdminAccess.standard();
>  
>              // to run commands as root, we use the runScript option in the template.
> -            if(provider.equalsIgnoreCase("virtualbox"))
> -               templateBuilder.options(overrideLoginUser(loginUser).runScript(bootInstructions));
> -            else
> -               templateBuilder.options(runScript(bootInstructions));
> -            
> -            NodeMetadata node = getOnlyElement(compute.createNodesInGroup(groupName,
1, templateBuilder.build()));
> +            templateBuilder.options(runScript(bootInstructions));
> +
> +            Template template = templateBuilder.build();
> +
> +            if (providerIsGCE) {
> +                GoogleComputeEngineTemplateOptions templateOptions = template.getOptions().as(GoogleComputeEngineTemplateOptions.class);
> +                templateOptions.overrideLoginUser("andrea");
> +                templateOptions.authorizePublicKey("ssh-rsa " +
> +                        "AAAAB3NzaC1yc2EAAAADAQABAAABAQDNnvPZ25wZK19grrbal6R5JP1hLRBUuNh86KxZVMAFkGd5ouVSgO9dFajHZ45Q4mbaTkdOiqf7otMLDzkaztEa7oLK7Jso0Y0LOi+nT4gf38rvbEF5mq069G9b9XqlNleaGnpLuTN54iEK8c4TWZxIJqgelHEHhjp7V1asmilBbpZDmwA5cTt9vGJIhqA/BptKH3folZKeAQjRa1ZRSwSQUnk9rBKn4PKSRDojVa9A9jKt4qboJh5q7ZjtE8z+665F/4TgLzElTXUA8+uUFGpuynMSmQEt301e18dXAl+vBr8fMiThcoVVbdVdqdjXsw75fMXPAgqhjrw8k3+0/4P9
andrea@bigmac.local");

[minor] Indent?

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-examples/pull/72/files#r27539339
Mime
View raw message