Skip to main content

TerraformCommandError

Thrown when a terraform or terragrunt command exits non-zero. Carries the command's arguments, exit code, the stdout of a command asked for JSON, and the end of its stderr.

@group

Errors/Terraform

Hierarchy

  • Error
    • TerraformCommandError

Index

Constructors

constructor

  • TerraformCommandError(message: string, args: string[], exitCode: number, stdout: string, stderr: string): TerraformCommandError
  • Parameters

    • message: string

      The error message.

    • args: string[]

      The arguments the command was invoked with.

    • exitCode: number

      The command's exit code.

    • stdout: string

      The command's standard output, kept only for a command asked for JSON.

    • stderr: string

      The last 64 KB the command wrote to standard error.

    Returns TerraformCommandError

Properties

readonlyargs

args: string[]

readonlyexitCode

exitCode: number

readonlystderr

stderr: string

readonlystdout

stdout: string