Show / Hide Table of Contents

Class CfnInstance.PortProperty

Port is a property of the Networking property. It describes information about ports for an instance.

Inheritance
object
CfnInstance.PortProperty
Implements
CfnInstance.IPortProperty
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.Lightsail
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnInstance.PortProperty : CfnInstance.IPortProperty
Syntax (vb)
Public Class CfnInstance.PortProperty Implements CfnInstance.IPortProperty
Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.Lightsail;

             var portProperty = new PortProperty {
                 AccessDirection = "accessDirection",
                 AccessFrom = "accessFrom",
                 AccessType = "accessType",
                 CidrListAliases = new [] { "cidrListAliases" },
                 Cidrs = new [] { "cidrs" },
                 CommonName = "commonName",
                 FromPort = 123,
                 Ipv6Cidrs = new [] { "ipv6Cidrs" },
                 Protocol = "protocol",
                 ToPort = 123
             };

Synopsis

Constructors

PortProperty()

Port is a property of the Networking property. It describes information about ports for an instance.

Properties

AccessDirection

The access direction ( inbound or outbound ).

AccessFrom

The location from which access is allowed.

AccessType

The type of access ( Public or Private ).

CidrListAliases

An alias that defines access for a preconfigured range of IP addresses.

Cidrs

The IPv4 address, or range of IPv4 addresses (in CIDR notation) that are allowed to connect to an instance through the ports, and the protocol.

CommonName

The common name of the port information.

FromPort

The first port in a range of open ports on an instance.

Ipv6Cidrs

The IPv6 address, or range of IPv6 addresses (in CIDR notation) that are allowed to connect to an instance through the ports, and the protocol.

Protocol

The IP protocol name.

ToPort

The last port in a range of open ports on an instance.

Constructors

PortProperty()

Port is a property of the Networking property. It describes information about ports for an instance.

public PortProperty()
Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.Lightsail;

             var portProperty = new PortProperty {
                 AccessDirection = "accessDirection",
                 AccessFrom = "accessFrom",
                 AccessType = "accessType",
                 CidrListAliases = new [] { "cidrListAliases" },
                 Cidrs = new [] { "cidrs" },
                 CommonName = "commonName",
                 FromPort = 123,
                 Ipv6Cidrs = new [] { "ipv6Cidrs" },
                 Protocol = "protocol",
                 ToPort = 123
             };

Properties

AccessDirection

The access direction ( inbound or outbound ).

public string? AccessDirection { get; set; }
Property Value

string

Remarks
Lightsail currently supports only <code>inbound</code> access direction.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-accessdirection

AccessFrom

The location from which access is allowed.

public string? AccessFrom { get; set; }
Property Value

string

Remarks

For example, Anywhere (0.0.0.0/0) , or Custom if a specific IP address or range of IP addresses is allowed.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-accessfrom

AccessType

The type of access ( Public or Private ).

public string? AccessType { get; set; }
Property Value

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-accesstype

CidrListAliases

An alias that defines access for a preconfigured range of IP addresses.

public string[]? CidrListAliases { get; set; }
Property Value

string[]

Remarks

The only alias currently supported is lightsail-connect , which allows IP addresses of the browser-based RDP/SSH client in the Lightsail console to connect to your instance.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-cidrlistaliases

Cidrs

The IPv4 address, or range of IPv4 addresses (in CIDR notation) that are allowed to connect to an instance through the ports, and the protocol.

public string[]? Cidrs { get; set; }
Property Value

string[]

Remarks
The <code>ipv6Cidrs</code> parameter lists the IPv6 addresses that are allowed to connect to an instance.

Examples:

    See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-cidrs

    CommonName

    The common name of the port information.

    public string? CommonName { get; set; }
    Property Value

    string

    Remarks

    See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-commonname

    FromPort

    The first port in a range of open ports on an instance.

    public double? FromPort { get; set; }
    Property Value

    double?

    Remarks

    Allowed ports:

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-fromport

      Ipv6Cidrs

      The IPv6 address, or range of IPv6 addresses (in CIDR notation) that are allowed to connect to an instance through the ports, and the protocol.

      public string[]? Ipv6Cidrs { get; set; }
      Property Value

      string[]

      Remarks

      Only devices with an IPv6 address can connect to an instance through IPv6; otherwise, IPv4 should be used.

      The <code>cidrs</code> parameter lists the IPv4 addresses that are allowed to connect to an instance.
      

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-ipv6cidrs

      Protocol

      The IP protocol name.

      public string? Protocol { get; set; }
      Property Value

      string

      Remarks

      The name can be one of the following:

        See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-protocol

        ToPort

        The last port in a range of open ports on an instance.

        public double? ToPort { get; set; }
        Property Value

        double?

        Remarks

        Allowed ports:

          See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-instance-port.html#cfn-lightsail-instance-port-toport

          Implements

          CfnInstance.IPortProperty
          Back to top Generated by DocFX