Class: AWSCDK::EVS::CfnEnvironment::HostInfoForCreateProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
evs/cfn_environment.rb

Overview

An object that represents a host.

You cannot use dedicated_host_id and placement_group_id together in the same HostInfoForCreate object. This results in a ValidationException response.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(host_name:, instance_type:, key_name:, dedicated_host_id: nil, placement_group_id: nil) ⇒ HostInfoForCreateProperty

Returns a new instance of HostInfoForCreateProperty.

Parameters:

  • host_name (String)

    The DNS hostname of the host.

  • instance_type (String)

    The EC2 instance type that represents the host.

  • key_name (String)

    The name of the SSH key that is used to access the host.

  • dedicated_host_id (String, nil) (defaults to: nil)

    The unique ID of the Amazon EC2 Dedicated Host.

  • placement_group_id (String, nil) (defaults to: nil)

    The unique ID of the placement group where the host is placed.



872
873
874
875
876
877
878
879
880
881
882
883
# File 'evs/cfn_environment.rb', line 872

def initialize(host_name:, instance_type:, key_name:, dedicated_host_id: nil, placement_group_id: nil)
  @host_name = host_name
  Jsii::Type.check_type(@host_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "hostName")
  @instance_type = instance_type
  Jsii::Type.check_type(@instance_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "instanceType")
  @key_name = key_name
  Jsii::Type.check_type(@key_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "keyName")
  @dedicated_host_id = dedicated_host_id
  Jsii::Type.check_type(@dedicated_host_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "dedicatedHostId") unless @dedicated_host_id.nil?
  @placement_group_id = placement_group_id
  Jsii::Type.check_type(@placement_group_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "placementGroupId") unless @placement_group_id.nil?
end

Instance Attribute Details

#dedicated_host_idString? (readonly)

The unique ID of the Amazon EC2 Dedicated Host.



906
907
908
# File 'evs/cfn_environment.rb', line 906

def dedicated_host_id
  @dedicated_host_id
end

#host_nameString (readonly)

The DNS hostname of the host.

DNS hostnames for hosts must be unique across Amazon EVS environments and within VCF.



891
892
893
# File 'evs/cfn_environment.rb', line 891

def host_name
  @host_name
end

#instance_typeString (readonly)

The EC2 instance type that represents the host.



896
897
898
# File 'evs/cfn_environment.rb', line 896

def instance_type
  @instance_type
end

#key_nameString (readonly)

The name of the SSH key that is used to access the host.



901
902
903
# File 'evs/cfn_environment.rb', line 901

def key_name
  @key_name
end

#placement_group_idString? (readonly)

The unique ID of the placement group where the host is placed.



911
912
913
# File 'evs/cfn_environment.rb', line 911

def placement_group_id
  @placement_group_id
end

Class Method Details

.jsii_propertiesObject



913
914
915
916
917
918
919
920
921
# File 'evs/cfn_environment.rb', line 913

def self.jsii_properties
  {
    :host_name => "hostName",
    :instance_type => "instanceType",
    :key_name => "keyName",
    :dedicated_host_id => "dedicatedHostId",
    :placement_group_id => "placementGroupId",
  }
end

Instance Method Details

#to_jsiiObject



923
924
925
926
927
928
929
930
931
932
933
# File 'evs/cfn_environment.rb', line 923

def to_jsii
  result = {}
  result.merge!({
    "hostName" => @host_name,
    "instanceType" => @instance_type,
    "keyName" => @key_name,
    "dedicatedHostId" => @dedicated_host_id,
    "placementGroupId" => @placement_group_id,
  })
  result.compact
end