Class: RubyTerraform::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/ruby_terraform.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



92
93
94
95
96
97
98
# File 'lib/ruby_terraform.rb', line 92

def initialize
  @binary = 'terraform'
  @logger = default_logger
  @stdin = ''
  @stdout = $stdout
  @stderr = $stderr
end

Instance Attribute Details

#binaryObject

Returns the value of attribute binary.



84
85
86
# File 'lib/ruby_terraform.rb', line 84

def binary
  @binary
end

#loggerObject

Returns the value of attribute logger.



84
85
86
# File 'lib/ruby_terraform.rb', line 84

def logger
  @logger
end

#stderrObject

Returns the value of attribute stderr.



84
85
86
# File 'lib/ruby_terraform.rb', line 84

def stderr
  @stderr
end

#stdinObject

Returns the value of attribute stdin.



84
85
86
# File 'lib/ruby_terraform.rb', line 84

def stdin
  @stdin
end

#stdoutObject

Returns the value of attribute stdout.



84
85
86
# File 'lib/ruby_terraform.rb', line 84

def stdout
  @stdout
end

Instance Method Details

#default_loggerObject



86
87
88
89
90
# File 'lib/ruby_terraform.rb', line 86

def default_logger
  logger = Logger.new($stdout)
  logger.level = Logger::INFO
  logger
end