You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by he...@apache.org on 2015/05/22 11:05:01 UTC
[16/23] incubator-brooklyn git commit: enable password auth if needed
when a password is requested to be set for a user being created
enable password auth if needed when a password is requested to be set for a user being created
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/3ed4459e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/3ed4459e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/3ed4459e
Branch: refs/heads/master
Commit: 3ed4459e70864e15c6d706a7ba5ee90a8037fec5
Parents: 38c92c8
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Fri May 8 17:11:37 2015 +0100
Committer: Alex Heneveld <al...@cloudsoftcorp.com>
Committed: Fri May 8 18:51:50 2015 +0100
----------------------------------------------------------------------
.../src/main/java/brooklyn/location/jclouds/JcloudsLocation.java | 3 +++
1 file changed, 3 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/3ed4459e/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
----------------------------------------------------------------------
diff --git a/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java b/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
index 4e1c24e..1118409 100644
--- a/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
+++ b/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsLocation.java
@@ -1555,6 +1555,9 @@ public class JcloudsLocation extends AbstractCloudMachineProvisioningLocation im
createdUserCreds = LoginCredentials.builder().user(user).privateKey(privKey).build();
} else if (passwordToSet!=null) {
createdUserCreds = LoginCredentials.builder().user(user).password(passwordToSet).build();
+
+ // if setting a password also ensure password is permitted for ssh
+ statements.add(org.jclouds.scriptbuilder.statements.ssh.SshStatements.sshdConfig(ImmutableMap.of("PasswordAuthentication", "yes")));
}
}