Method: RubyTerraform::ClassMethods#providers

Defined in:
lib/ruby_terraform.rb

#providers(parameters = {}, invocation_options = {}) ⇒ Object

Invokes the terraform providers command which prints out a tree of modules in the referenced configuration annotated with their provider requirements.

This provides an overview of all of the provider requirements across all referenced modules, as an aid to understanding why particular provider plugins are needed and why particular versions are selected.

Examples:

Basic Invocation

RubyTerraform.providers

Parameters:

  • parameters (defaults to: {})

    The parameters used to invoke the command

  • invocation_options (Hash<String, Object>) (defaults to: {})

    Additional options controlling the invocation of the command.

Options Hash (parameters):

  • :directory (String)

    The path to a directory containing terraform configuration (deprecated in terraform 0.14, removed in terraform 0.15, use :chdir instead).

  • :chdir (String)

    The path of a working directory to switch to before executing the given subcommand.

Options Hash (invocation_options):

  • :environment (Hash<String, String>)

    A map of environment variables to expose at command invocation time.



699
700
701
702
# File 'lib/ruby_terraform.rb', line 699

def providers(parameters = {}, invocation_options = {})
  exec(RubyTerraform::Commands::Providers,
       parameters, invocation_options)
end