Skip to content
Permalink
Browse files
Added oauth.endpoint property
  • Loading branch information
jtjk authored and nacx committed Apr 13, 2016
1 parent abc789d commit 6401800075a1aeee82608f2a780b2e8d5129bfbc
Showing 1 changed file with 8 additions and 0 deletions.
@@ -101,6 +101,8 @@ public static enum Action {
public static int PARAMETERS = 5;
public static String INVALID_SYNTAX = "Invalid number of parameters. Syntax is: provider identity credential groupName (add|exec|run|destroy)";

public static final String PROPERTY_OAUTH_ENDPOINT = "oauth.endpoint";

public static void main(String[] args) {
if (args.length < PARAMETERS)
throw new IllegalArgumentException(INVALID_SYNTAX);
@@ -268,6 +270,12 @@ private static ComputeService initComputeService(String provider, String identit
long scriptTimeout = TimeUnit.MILLISECONDS.convert(20, TimeUnit.MINUTES);
properties.setProperty(TIMEOUT_SCRIPT_COMPLETE, scriptTimeout + "");

// set oauth endpoint property if set in system property
String oAuthEndpoint = System.getProperty(PROPERTY_OAUTH_ENDPOINT);
if (oAuthEndpoint != null) {
properties.setProperty(PROPERTY_OAUTH_ENDPOINT, oAuthEndpoint);
}

// example of injecting a ssh implementation
Iterable<Module> modules = ImmutableSet.<Module> of(
new SshjSshClientModule(),

0 comments on commit 6401800

Please sign in to comment.