apiVersion: v1
kind: Service
metadata:
  name: rabbit
spec:
  type: NodePort
  selector:
    name: rabbit
  ports:
      # By default and for convenience, the `targetPort` is set to the same value as the `port` field.
    - port: 5672
      targetPort: 5672
      # Optional field
      # By default and for convenience, the Kubernetes control plane will allocate a port from a range (default: 30000-32767)
      nodePort: 30001
