Class: Terraspace::Builder::Allow::Stack

Inherits:
Base
  • Object
show all
Defined in:
lib/terraspace/builder/allow/stack.rb

Instance Method Summary collapse

Methods inherited from Base

#allowed?, #allows, #check!, #denys, #initialize

Methods included from App::CallableOption::Concern

#callable_option

Constructor Details

This class inherits a constructor from Terraspace::Builder::Allow::Base

Instance Method Details

#check_valueObject

interface method



13
14
15
# File 'lib/terraspace/builder/allow/stack.rb', line 13

def check_value
  @mod.name
end

#messageObject

interface method



4
5
6
7
8
9
10
# File 'lib/terraspace/builder/allow/stack.rb', line 4

def message
  messages = []
  messages << "This stack is not allowed to be used for TS_ENV=#{Terraspace.env}"
  messages << "Allow stacks: #{allows.join(', ')}" if allows
  messages << "Deny stacks: #{denys.join(', ')}" if denys
  messages.join("\n")
end