redhat-developer / kam

GitOps Application Manager: An opinionated CLI that generates the Kubernetes resources for managing your Tekton-based CI manifests, ArgoCD-based CD manifests and Application manifests in Git.
Apache License 2.0
145 stars 83 forks source link

Generated event listener route using targetPort 8080 instead of http-listener label #243

Closed awisniew90 closed 3 years ago

awisniew90 commented 3 years ago

Describe the bug The gitops-webhook-event-listener-route that is bootstrapped is using a targetPort value of 8080 which isnt corrently hitting the event listener pod on port 8000. This is causing the git webhook to fail with an HTTP 503.

To Reproduce Steps to reproduce the behavior: (Following these instructions: https://github.com/redhat-developer/kam/tree/master/docs/journey/day1)

  1. Run kam bootstrap ...

Expected behavior The gitops-webhook-event-listener-route that is generated should have a targetPort value of the http-listener label. This would line up with the el-cicd-event-listener service's spec and correctly route the request to the pod's port 8000:

ports:
    - name: http-listener
      protocol: TCP
      port: 8080
      targetPort: 8000
chetan-rns commented 3 years ago

@awisniew90 I think this got fixed in PR https://github.com/redhat-developer/kam/pull/233 and should be available in kam v0.0.32

awisniew90 commented 3 years ago

Verified that v0.0.32 is using the correct port 8000 now. Any reason why the port value is still hard coded rather than using the http-listener label?

chetan-rns commented 3 years ago

@awisniew90 I agree, the route should have the port name instead of the hardcoded number

  port:
    targetPort: http-listener
chetan-rns commented 3 years ago

Closed by #247