Package com.pulumi.automation
Class LocalPulumiCommand
- java.lang.Object
-
- com.pulumi.automation.LocalPulumiCommand
-
- All Implemented Interfaces:
PulumiCommand
public class LocalPulumiCommand extends java.lang.Object implements PulumiCommand
APulumiCommandimplementation that uses a locally installed Pulumi CLI.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static LocalPulumiCommandcreate()Creates a newLocalPulumiCommandinstance.static LocalPulumiCommandcreate(LocalPulumiCommandOptions options)Creates a newLocalPulumiCommandinstance.CommandResultrun(java.util.List<java.lang.String> args, CommandRunOptions options)Runs the Pulumi command.Versionversion()The version of the Pulumi CLI that is being used.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.pulumi.automation.PulumiCommand
run
-
-
-
-
Method Detail
-
create
public static LocalPulumiCommand create() throws AutomationException
Creates a newLocalPulumiCommandinstance.- Returns:
- a new
LocalPulumiCommandinstance - Throws:
AutomationException
-
create
public static LocalPulumiCommand create(LocalPulumiCommandOptions options) throws AutomationException
Creates a newLocalPulumiCommandinstance.- Parameters:
options- options to configure theLocalPulumiCommand- Returns:
- a new
LocalPulumiCommandinstance - Throws:
AutomationException
-
version
@Nullable public Version version()
Description copied from interface:PulumiCommandThe version of the Pulumi CLI that is being used.- Specified by:
versionin interfacePulumiCommand- Returns:
- the version of the Pulumi CLI or
null
-
run
public CommandResult run(java.util.List<java.lang.String> args, CommandRunOptions options) throws AutomationException
Runs the Pulumi command.- Specified by:
runin interfacePulumiCommand- Parameters:
args- the arguments to pass to the commandoptions- the options for running the command- Returns:
- the command result
- Throws:
AutomationException- if the command fails
-
-