module Terraspace::Terraform::Api::Client

Public Instance Methods

api() click to toggle source

api may be overridden in classes including this Concern

# File lib/terraspace/terraform/api/client.rb, line 24
def api
  return unless backend.dig('remote','workspaces') # in case called by terraspace down demo -y --destroy-workspace with a non-remote backend
  Terraspace::Terraform::Api.new(@mod, remote)
end
backend() click to toggle source

backend may be overridden in classes including this Concern

# File lib/terraspace/terraform/api/client.rb, line 18
def backend
  Terraspace::Compiler::Backend::Parser.new(@mod).result
end
build() click to toggle source
# File lib/terraspace/terraform/api/client.rb, line 12
def build
  Terraspace::Builder.new(@options).run
end
remote() click to toggle source
# File lib/terraspace/terraform/api/client.rb, line 4
def remote
  backend["remote"]
end
workspace_name() click to toggle source
# File lib/terraspace/terraform/api/client.rb, line 8
def workspace_name
  remote['workspaces']['name']
end