code: func FindPort(pod *v1.Pod, svcPort *v1.ServicePort) (int, error) {
  	portName := svcPort.TargetPort
  	switch portName.Type {
  	case intstr.String:
  		name := portName.StrVal
  		for _, container := range pod.Spec.Containers {
  			for _, port := range container.Ports {
  				if port.Name == name && port.Protocol == svcPort.Protocol {
  					return int(port.ContainerPort), nil
  				}
  			}
  		}
  	case intstr.Int:
  		return portName.IntValue(), nil
  	}
  
  	return 0, fmt.Errorf("no suitable port for manifest: %s", pod.UID)
  }
docs: // FindPort locates the container port for the given pod and portName.  If the
  // targetPort is a number, use that.  If the targetPort is a string, look that
  // string up in all named ports in all containers in the target pod.  If no
  // match is found, fail.