Class: AWSCDK::ECS::CloudMapNamespaceOptions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::ECS::CloudMapNamespaceOptions
- Defined in:
- ecs/cloud_map_namespace_options.rb
Overview
The options for creating an AWS Cloud Map namespace.
Instance Attribute Summary collapse
-
#name ⇒ String
readonly
The name of the namespace, such as example.com.
-
#type ⇒ AWSCDK::ServiceDiscovery::NamespaceType?
readonly
The type of CloudMap Namespace to create.
-
#use_for_service_connect ⇒ Boolean?
readonly
This property specifies whether to set the provided namespace as the service connect default in the cluster properties.
-
#vpc ⇒ AWSCDK::EC2::IVPC?
readonly
The VPC to associate the namespace with.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(name:, type: nil, use_for_service_connect: nil, vpc: nil) ⇒ CloudMapNamespaceOptions
constructor
A new instance of CloudMapNamespaceOptions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(name:, type: nil, use_for_service_connect: nil, vpc: nil) ⇒ CloudMapNamespaceOptions
Returns a new instance of CloudMapNamespaceOptions.
11 12 13 14 15 16 17 18 19 20 |
# File 'ecs/cloud_map_namespace_options.rb', line 11 def initialize(name:, type: nil, use_for_service_connect: nil, vpc: nil) @name = name Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") @type = type Jsii::Type.check_type(@type, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc2VydmljZWRpc2NvdmVyeS5OYW1lc3BhY2VUeXBlIn0=")), "type") unless @type.nil? @use_for_service_connect = use_for_service_connect Jsii::Type.check_type(@use_for_service_connect, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "useForServiceConnect") unless @use_for_service_connect.nil? @vpc = vpc Jsii::Type.check_type(@vpc, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZWMyLklWcGMifQ==")), "vpc") unless @vpc.nil? end |
Instance Attribute Details
#name ⇒ String (readonly)
The name of the namespace, such as example.com.
25 26 27 |
# File 'ecs/cloud_map_namespace_options.rb', line 25 def name @name end |
#type ⇒ AWSCDK::ServiceDiscovery::NamespaceType? (readonly)
Default: PrivateDns
The type of CloudMap Namespace to create.
30 31 32 |
# File 'ecs/cloud_map_namespace_options.rb', line 30 def type @type end |
#use_for_service_connect ⇒ Boolean? (readonly)
Default: false
This property specifies whether to set the provided namespace as the service connect default in the cluster properties.
35 36 37 |
# File 'ecs/cloud_map_namespace_options.rb', line 35 def use_for_service_connect @use_for_service_connect end |
#vpc ⇒ AWSCDK::EC2::IVPC? (readonly)
Default: VPC of the cluster for Private DNS Namespace, otherwise none
The VPC to associate the namespace with.
This property is required for private DNS namespaces.
42 43 44 |
# File 'ecs/cloud_map_namespace_options.rb', line 42 def vpc @vpc end |
Class Method Details
.jsii_properties ⇒ Object
44 45 46 47 48 49 50 51 |
# File 'ecs/cloud_map_namespace_options.rb', line 44 def self.jsii_properties { :name => "name", :type => "type", :use_for_service_connect => "useForServiceConnect", :vpc => "vpc", } end |
Instance Method Details
#to_jsii ⇒ Object
53 54 55 56 57 58 59 60 61 62 |
# File 'ecs/cloud_map_namespace_options.rb', line 53 def to_jsii result = {} result.merge!({ "name" => @name, "type" => @type, "useForServiceConnect" => @use_for_service_connect, "vpc" => @vpc, }) result.compact end |