public class RunScriptOnNodeUsingSsh extends Object implements RunScriptOnNode
RunScriptOnNode.Factory| Modifier and Type | Field and Description | 
|---|---|
protected com.google.common.eventbus.EventBus | 
eventBus  | 
protected Logger | 
logger  | 
static String | 
MARKER  | 
protected NodeMetadata | 
node  | 
protected boolean | 
runAsRoot  | 
protected SshClient | 
ssh  | 
protected com.google.common.base.Function<NodeMetadata,SshClient> | 
sshFactory  | 
protected Statement | 
statement  | 
| Constructor and Description | 
|---|
RunScriptOnNodeUsingSsh(com.google.common.base.Function<NodeMetadata,SshClient> sshFactory,
                       com.google.common.eventbus.EventBus eventBus,
                       NodeMetadata node,
                       Statement statement,
                       RunScriptOptions options)  | 
| Modifier and Type | Method and Description | 
|---|---|
ExecResponse | 
call()
Note that  
RunScriptOnNode.init() must be called first. | 
String | 
execAsRoot(String command)  | 
protected String | 
execScriptAsDefaultUser(String command)  | 
NodeMetadata | 
getNode()
the node this command is being executed on. 
 | 
Statement | 
getStatement()  | 
RunScriptOnNode | 
init()
verifies that the command can execute on the node. 
 | 
protected ExecResponse | 
runCommand(String command)  | 
String | 
toString()  | 
public static final String MARKER
@Named(value="jclouds.compute") protected Logger logger
protected final com.google.common.base.Function<NodeMetadata,SshClient> sshFactory
protected final com.google.common.eventbus.EventBus eventBus
protected final NodeMetadata node
protected final Statement statement
protected final boolean runAsRoot
protected SshClient ssh
public RunScriptOnNodeUsingSsh(com.google.common.base.Function<NodeMetadata,SshClient> sshFactory, com.google.common.eventbus.EventBus eventBus, NodeMetadata node, Statement statement, RunScriptOptions options)
public ExecResponse call()
RunScriptOnNodeRunScriptOnNode.init() must be called first.call in interface Callable<ExecResponse>call in interface RunScriptOnNodepublic RunScriptOnNode init()
RunScriptOnNodeinit in interface RunScriptOnNodeprotected ExecResponse runCommand(String command)
public NodeMetadata getNode()
RunScriptOnNodegetNode in interface RunScriptOnNodepublic Statement getStatement()
getStatement in interface RunScriptOnNodeCopyright © 2009-2013 jclouds. All Rights Reserved.