Class: TerraformConfig::Gvc
- Defined in:
- lib/core/terraform_config/gvc.rb
Constant Summary
Constants included from Dsl
Instance Attribute Summary collapse
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#domain ⇒ Object
readonly
Returns the value of attribute domain.
-
#env ⇒ Object
readonly
Returns the value of attribute env.
-
#load_balancer ⇒ Object
readonly
Returns the value of attribute load_balancer.
-
#locations ⇒ Object
readonly
Returns the value of attribute locations.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#pull_secrets ⇒ Object
readonly
Returns the value of attribute pull_secrets.
-
#tags ⇒ Object
readonly
Returns the value of attribute tags.
Instance Method Summary collapse
- #importable? ⇒ Boolean
-
#initialize(name:, description: nil, tags: nil, domain: nil, locations: nil, pull_secrets: nil, env: nil, load_balancer: nil) ⇒ Gvc
constructor
rubocop:disable Metrics/ParameterLists.
- #reference ⇒ Object
- #to_tf ⇒ Object
Methods inherited from Base
Methods included from Dsl
Constructor Details
#initialize(name:, description: nil, tags: nil, domain: nil, locations: nil, pull_secrets: nil, env: nil, load_balancer: nil) ⇒ Gvc
rubocop:disable Metrics/ParameterLists
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/core/terraform_config/gvc.rb', line 7 def initialize( # rubocop:disable Metrics/ParameterLists name:, description: nil, tags: nil, domain: nil, locations: nil, pull_secrets: nil, env: nil, load_balancer: nil ) super() @name = name @description = description @tags = @domain = domain @locations = locations @pull_secrets = pull_secrets @env = env @load_balancer = load_balancer&.deep_underscore_keys&.deep_symbolize_keys end |
Instance Attribute Details
#description ⇒ Object (readonly)
Returns the value of attribute description.
5 6 7 |
# File 'lib/core/terraform_config/gvc.rb', line 5 def description @description end |
#domain ⇒ Object (readonly)
Returns the value of attribute domain.
5 6 7 |
# File 'lib/core/terraform_config/gvc.rb', line 5 def domain @domain end |
#env ⇒ Object (readonly)
Returns the value of attribute env.
5 6 7 |
# File 'lib/core/terraform_config/gvc.rb', line 5 def env @env end |
#load_balancer ⇒ Object (readonly)
Returns the value of attribute load_balancer.
5 6 7 |
# File 'lib/core/terraform_config/gvc.rb', line 5 def load_balancer @load_balancer end |
#locations ⇒ Object (readonly)
Returns the value of attribute locations.
5 6 7 |
# File 'lib/core/terraform_config/gvc.rb', line 5 def locations @locations end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
5 6 7 |
# File 'lib/core/terraform_config/gvc.rb', line 5 def name @name end |
#pull_secrets ⇒ Object (readonly)
Returns the value of attribute pull_secrets.
5 6 7 |
# File 'lib/core/terraform_config/gvc.rb', line 5 def pull_secrets @pull_secrets end |
#tags ⇒ Object (readonly)
Returns the value of attribute tags.
5 6 7 |
# File 'lib/core/terraform_config/gvc.rb', line 5 def @tags end |
Instance Method Details
#importable? ⇒ Boolean
29 30 31 |
# File 'lib/core/terraform_config/gvc.rb', line 29 def importable? true end |
#reference ⇒ Object
33 34 35 |
# File 'lib/core/terraform_config/gvc.rb', line 33 def reference "cpln_gvc.#{name}" end |
#to_tf ⇒ Object
37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/core/terraform_config/gvc.rb', line 37 def to_tf block :resource, :cpln_gvc, name do argument :name, name argument :description, description, optional: true argument :tags, , optional: true argument :domain, domain, optional: true argument :locations, locations, optional: true argument :pull_secrets, pull_secrets, optional: true argument :env, env, optional: true load_balancer_tf end end |