Interface ContainerPort

ContainerPort represents the information about how to expose a container port on a [Service].

interface ContainerPort {
    external?: boolean;
    port: number;
    protocol?: ContainerProtocol;
    targetPort?: number;
}

Properties

external?: boolean

Whether the port should be exposed externally. Defaults to false.

port: number

The incoming port where the service exposes the endpoint.

The protocol to use for exposing the service:

  • tcp: Expose TCP externaly and to the container.
  • udp: Expose UDP externally and to the container.
  • http: Expose HTTP externally and to the container.
  • https: Expose HTTPS externally and HTTP to the container.
targetPort?: number

The target port on the backing container. Defaults to the value of [port].

Generated using TypeDoc