Interface ContainerPort

  • All Superinterfaces:
    software.amazon.jsii.JsiiSerializable
    All Known Implementing Classes:
    ContainerPort.Jsii$Proxy

    @Generated(value="jsii-pacmak/1.69.0 (build f656c31)",
               date="2022-10-05T02:57:36.364Z")
    @Stability(Stable)
    public interface ContainerPort
    extends software.amazon.jsii.JsiiSerializable
    ContainerPort represents a network port in a single container.
    • Method Detail

      • getContainerPort

        @Stability(Stable)
        @NotNull
        Number getContainerPort()
        Number of port to expose on the pod's IP address.

        This must be a valid port number, 0 < x < 65536.

      • getHostIp

        @Stability(Stable)
        @Nullable
        default String getHostIp()
        What host IP to bind the external port to.
      • getHostPort

        @Stability(Stable)
        @Nullable
        default Number getHostPort()
        Number of port to expose on the host.

        If specified, this must be a valid port number, 0 < x < 65536. If HostNetwork is specified, this must match ContainerPort. Most containers do not need this.

      • getName

        @Stability(Stable)
        @Nullable
        default String getName()
        If specified, this must be an IANA_SVC_NAME and unique within the pod.

        Each named port in a pod must have a unique name. Name for the port that can be referred to by services.

      • getProtocol

        @Stability(Stable)
        @Nullable
        default String getProtocol()
        Protocol for port.

        Must be UDP, TCP, or SCTP. Defaults to "TCP".

        Default: TCP".