divan / expvarmon

TermUI based monitor for Go apps using expvars (/debug/vars). Quickest way to monitor your Go app(s).
MIT License
2.02k stars 101 forks source link

hacked up support for https URLs #5

Closed nightlyone closed 9 years ago

nightlyone commented 9 years ago

since many real life services are behind SSL only

Hi @divan this change is just the minimal version to get HTTPS based URLs working. I am glad to beautify it a lot :smile:

divan commented 9 years ago

Thanks. I've merged it, but here are few remarks: 1) It's generally wise no to expose /debug/vars to the world, even in a secure way. It's safer to start separate HTTP server in it's own goroutine for that. 2) It will probably will require setting 'SkipVerify' option for self-signed HTTPS endpoints.

I've also refactored the whole url-handling code, so now the url.URL is used instead of just 'ports'. I removed "-url" flag, and made urls available in "-ports". Like this "1234-1235,https://example.com:2000-2002". The word 'ports' is not the best here, but I left it for compatibility.

Anyway, thanks for the contribution!

nightlyone commented 9 years ago

Thanks for your refactoring. That looks awesomely useful now!