Class: AWSCDK::Grafana::CfnWorkspace::NetworkAccessControlProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
grafana/cfn_workspace.rb

Overview

The configuration settings for in-bound network access to your workspace.

When this is configured, only listed IP addresses and VPC endpoints will be able to access your workspace. Standard Grafana authentication and authorization are still required.

Access is granted to a caller that is in either the IP address list or the VPC endpoint list - they do not need to be in both.

If this is not configured, or is removed, then all IP addresses and VPC endpoints are allowed. Standard Grafana authentication and authorization are still required.

While both prefix_list_ids and vpce_ids are required, you can pass in an empty array of strings for either parameter if you do not want to allow any of that type.

If both are passed as empty arrays, no traffic is allowed to the workspace, because only explicitly allowed connections are accepted.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(prefix_list_ids: nil, vpce_ids: nil) ⇒ NetworkAccessControlProperty

Returns a new instance of NetworkAccessControlProperty.

Parameters:

  • prefix_list_ids (Array<String>, nil) (defaults to: nil)

    An array of prefix list IDs.

  • vpce_ids (Array<String>, nil) (defaults to: nil)

    An array of Amazon VPC endpoint IDs for the workspace.



928
929
930
931
932
933
# File 'grafana/cfn_workspace.rb', line 928

def initialize(prefix_list_ids: nil, vpce_ids: nil)
  @prefix_list_ids = prefix_list_ids
  Jsii::Type.check_type(@prefix_list_ids, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "prefixListIds") unless @prefix_list_ids.nil?
  @vpce_ids = vpce_ids
  Jsii::Type.check_type(@vpce_ids, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "vpceIds") unless @vpce_ids.nil?
end

Instance Attribute Details

#prefix_list_idsArray<String>? (readonly)

An array of prefix list IDs.

A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

Prefix list IDs have the format pl- *1a2b3c4d* .

For more information about prefix lists, see Group CIDR blocks using managed prefix lists in the Amazon Virtual Private Cloud User Guide .



945
946
947
# File 'grafana/cfn_workspace.rb', line 945

def prefix_list_ids
  @prefix_list_ids
end

#vpce_idsArray<String>? (readonly)

An array of Amazon VPC endpoint IDs for the workspace.

You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

VPC endpoint IDs have the format vpce- *1a2b3c4d* .

For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide .

The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.



958
959
960
# File 'grafana/cfn_workspace.rb', line 958

def vpce_ids
  @vpce_ids
end

Class Method Details

.jsii_propertiesObject



960
961
962
963
964
965
# File 'grafana/cfn_workspace.rb', line 960

def self.jsii_properties
  {
    :prefix_list_ids => "prefixListIds",
    :vpce_ids => "vpceIds",
  }
end

Instance Method Details

#to_jsiiObject



967
968
969
970
971
972
973
974
# File 'grafana/cfn_workspace.rb', line 967

def to_jsii
  result = {}
  result.merge!({
    "prefixListIds" => @prefix_list_ids,
    "vpceIds" => @vpce_ids,
  })
  result.compact
end