hcavarsan / kftray

manage multiple kubectl port-forward commands, with support for UDP, K8s proxy, and github state sync.
https://kftray.app/
MIT License
739 stars 70 forks source link

Port-forwarding connects but not going anywhere #266

Closed rafi-rr closed 1 month ago

rafi-rr commented 2 months ago

Describe the bug Using KFTray worked fine up until 2 weeks ago, the same configuration does connect but it doesn't reach the services. Using kubectl does work. How can I debug this?

Desktop (please complete the following information):

Additionally, the tray icon appears twice and blocks the "Apple" menu:

image
hcavarsan commented 2 months ago

Hey, do you know if this behavior started in version 0.12.1? Did it work in the previous version?

You can enable debug logs with some environment variables:

RUST_LOG="trace" KFTRAY_DEBUG="true" open /Applications/kftray.app

The logs file will be created in $HOME/.kftray/app.log

rafi-rr commented 2 months ago

Except for the UI issue, I can recreate the problem with 0.11.7 as well so I think this may be related to our Kubernetes deployment. However, standard kubectl port-forwarding works. Is there anything specific that I should look for in the log?

hcavarsan commented 2 months ago

@rafi-rr just search for Error logs when starting port forwarding to identify the root cause. for less verbose logging, use RUST_LOG="info" or RUST_LOG="debug" . if you need help, send me the error logs

rafi-rr commented 2 months ago

@hcavarsan How can I send you log?

Just making sure that you saw this bug as well:

image
hcavarsan commented 2 months ago

hey, you can send the error logs here in this issue. just try to find the specific port forwarding logs with the error. if you prefer email, send to hencavarsan@gmail.com.

related to the icon bug: my macbook's being repaired and i should check it next week. some users had similar issues with the new version, but many fixed it by restarting the app. i'll test/fix it when my mac's back.

rafi-rr commented 1 month ago

@hcavarsan I sent over logs since I couldn't find any errors there.

Regarding the icon, I can recreate it easily and with multiple screen, it just moves between screens.

edwardbarford commented 1 month ago

I'm also unable to complete requests.

I had to go back to v0.11.6 to get it working again.

This is on Windows x64

hcavarsan commented 1 month ago

Okay, @edwardbarford, thank you for the feedback. I'll work on this this week.

@rafi-rr, thank you for the logs. Regarding the icon issue, I've opened a separate issue, #268, to track that specific behavior. This will allow us to focus on the port forwarding issue in this thread.

I don't find any errors in the logs. Could you please test the issue in version v0.11.6 to see if it works in the previous version? You can follow these steps to check if there's an issue with the configurations:

  1. Export the configurations in the v0.11.6 version.
  2. Delete all configurations.
  3. Upgrade the kftray to v0.12.1.
  4. Import the configurations, close kftray, and open it again.

and see if port forward works.

also, you can provide me with some points to help me reproduce the issue:

  1. Send me the logs with RUST_LOG="trace" if that's okay with you.
  2. Send me the configurations you're trying to use for port forwarding.
  3. Send me the manifest from the pod and service for one of these configurations.

If you prefer, you can anonymize some information to provide only examples, just to help me reproduce the issue.

thanks

rafi-rr commented 1 month ago

@hcavarsan I can confirm that v0.11.6 works. One of the pods is a standard out-of-the-box ArgoCD server, for example and I'm port-forwarding 443 to 8080.

hcavarsan commented 1 month ago

fixed. could you check if it's working now?

https://github.com/hcavarsan/kftray/releases/tag/v0.12.2

rafi-rr commented 1 month ago

@hcavarsan Confirmed. It connects now.