public class CommandLauncher
extends hudson.slaves.ComputerLauncher
ComputerLauncher through a remote login mechanism like ssh/rsh.| Modifier and Type | Class and Description |
|---|---|
static class |
CommandLauncher.DescriptorImpl |
| Constructor and Description |
|---|
CommandLauncher(String command)
Constructor for use from UI.
|
CommandLauncher(String command,
hudson.EnvVars env)
Constructor for programmatic use.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getCommand() |
void |
launch(hudson.slaves.SlaveComputer computer,
hudson.model.TaskListener listener) |
@DataBoundConstructor public CommandLauncher(String command)
command - the command to run pending approvalCommandLauncher(String command, EnvVars env)public CommandLauncher(String command, hudson.EnvVars env)
command - the single command to run; note: this can't be a shell statement
(e.g. "echo foo > bar; baz" -- if you need to do that, either use
"sh -c" or write the expression into a script and point to the script)env - environment variables for the launcher to include when it runs the commandpublic String getCommand()
public void launch(hudson.slaves.SlaveComputer computer,
hudson.model.TaskListener listener)
launch in class hudson.slaves.ComputerLauncherCopyright © 2016–2019. All rights reserved.